mirror of
https://github.com/Choices-js/Choices.git
synced 2024-04-27 03:31:53 +02:00
172366d6fa
* expand browsers target * add eslint-plugin-compat * sort polyfils * adjust readme * add polyfills sync check action * only build js * trim * add Element.prototype.closest * add closest to demo links * fix ignore
25 lines
638 B
JavaScript
25 lines
638 B
JavaScript
|
|
// get polyfill settings from top level config
|
|
// @ts-ignore
|
|
const { settings } = require('../../../.eslintrc.json');
|
|
|
|
// Adding non-polyfilable Symbol-related functions as they are most probably
|
|
// behind the flag
|
|
|
|
settings.polyfills.push('Symbol.toStringTag', 'Symbol.for', 'Object.getOwnPropertySymbols', 'Object.getOwnPropertyDescriptors')
|
|
|
|
module.exports = /** @type {import('eslint').Linter.Config} */({
|
|
root: true,
|
|
extends: [
|
|
"plugin:compat/recommended"
|
|
],
|
|
parserOptions: {
|
|
// ensure that it's compatible with ES5 browsers, so, no `const`, etc
|
|
ecmaVersion: 5
|
|
},
|
|
env: {
|
|
browser: true
|
|
},
|
|
settings
|
|
})
|