Skip to content
This repository has been archived by the owner on May 22, 2024. It is now read-only.

Commit

Permalink
feat!: convert to ESM and vitest
Browse files Browse the repository at this point in the history
  • Loading branch information
danez committed Oct 27, 2022
1 parent dec4d3f commit dae3ce8
Show file tree
Hide file tree
Showing 48 changed files with 5,135 additions and 6,461 deletions.
20 changes: 8 additions & 12 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ const { overrides } = require('@netlify/eslint-config-node')

module.exports = {
extends: '@netlify/eslint-config-node',
parserOptions: {
sourceType: 'module',
},
rules: {
'import/extensions': ['error', 'ignorePackages'],
'n/no-missing-import': 'off',
// This is disabled because TypeScript transpiles some features currently
// unsupported by Node 12, i.e. optional chaining
// TODO: re-enable after dropping support for Node 12
'n/no-unsupported-features/es-syntax': 'off',
'no-magic-numbers': 'off',
// This rule enforces using Buffers with `JSON.parse()`. However, TypeScript
// does not recognize yet that `JSON.parse()` accepts Buffers as argument.
'unicorn/prefer-json-parse-buffer': 'off',
Expand Down Expand Up @@ -37,19 +37,15 @@ module.exports = {
},
},
{
files: 'tests/**/*.js',
files: 'tests/**/*.ts',
rules: {
'import/max-dependencies': 'off',
'max-lines-per-function': 'off',
'max-nested-callbacks': 'off',
'max-statements': 'off',
'no-magic-numbers': 'off',
'padding-line-between-statements': 'off',
},
},
{
files: '*.md/*.js',
parserOptions: {
sourceType: 'module',
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/no-explicit-any': 'off',
},
},
],
Expand Down
3 changes: 3 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
dist/
node_modules
tests/fixtures/

0 comments on commit dae3ce8

Please sign in to comment.