-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from chrisweb/preview
Merge preview into main
- Loading branch information
Showing
368 changed files
with
25,508 additions
and
5,272 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,107 @@ | ||
module.exports = { | ||
'env': { | ||
'browser': true, | ||
'es2021': true, | ||
'node': true | ||
root: true, | ||
parserOptions: { | ||
ecmaVersion: 'latest', | ||
sourceType: 'module', | ||
}, | ||
'extends': [ | ||
'eslint:recommended', | ||
'plugin:react/recommended', | ||
'plugin:@typescript-eslint/recommended', | ||
'next/core-web-vitals', | ||
], | ||
'overrides': [ | ||
], | ||
'parser': '@typescript-eslint/parser', | ||
'parserOptions': { | ||
'ecmaVersion': 'latest', | ||
'sourceType': 'module' | ||
'env': { | ||
browser: true, | ||
es2021: true, | ||
node: true, | ||
}, | ||
'plugins': [ | ||
'react', | ||
'@typescript-eslint' | ||
ignorePatterns: [ | ||
'node_modules/', | ||
'.next/', | ||
'.vscode/', | ||
'public/', | ||
// by default we always ignore our tests folder | ||
// to ensure the tests dont trigger errors in | ||
// staging / production deployments | ||
// comment out the next line to have eslint check | ||
// the test files (in development) | ||
'tests/eslint/', | ||
], | ||
'rules': { | ||
/*'indent': [ | ||
'error', | ||
4, | ||
],*/ | ||
'quotes': [ | ||
'error', | ||
'single', | ||
], | ||
'semi': [ | ||
'error', | ||
'never', | ||
], | ||
'@typescript-eslint/naming-convention': [ | ||
'error', | ||
{ | ||
'selector': 'interface', | ||
'format': [ | ||
'PascalCase' | ||
], | ||
'custom': { | ||
'regex': '^I[A-Z]', | ||
'match': true | ||
reportUnusedDisableDirectives: true, | ||
overrides: [ | ||
{ | ||
files: ['**/*.ts?(x)', '**/*.md?(x)'], | ||
extends: [ | ||
'next/core-web-vitals', | ||
], | ||
}, | ||
{ | ||
files: ['**/*.ts?(x)'], | ||
extends: [ | ||
'plugin:@react-three/recommended', | ||
// https://typescript-eslint.io/users/configs#recommended-configurations | ||
'plugin:@typescript-eslint/recommended-type-checked', | ||
'plugin:@typescript-eslint/stylistic-type-checked', | ||
], | ||
parser: '@typescript-eslint/parser', | ||
parserOptions: { | ||
sourceType: 'module', | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
warnOnUnsupportedTypeScriptVersion: true, | ||
project: './tsconfig.json', | ||
}, | ||
plugins: [ | ||
'@typescript-eslint', | ||
], | ||
rules: { | ||
quotes: [ | ||
'error', | ||
'single', | ||
{ "allowTemplateLiterals": true }, | ||
], | ||
semi: [ | ||
'error', | ||
'never', | ||
], | ||
'@typescript-eslint/naming-convention': [ | ||
'error', | ||
{ | ||
'selector': 'interface', | ||
'format': [ | ||
'PascalCase', | ||
], | ||
'custom': { | ||
'regex': '^I[A-Z]', | ||
'match': true, | ||
}, | ||
} | ||
], | ||
'@typescript-eslint/consistent-indexed-object-style': 'off', | ||
'@typescript-eslint/ban-ts-comment': [ | ||
'error', | ||
{ | ||
'ts-expect-error': 'allow-with-description', | ||
'ts-ignore': 'allow-with-description', | ||
'ts-nocheck': false, | ||
'ts-check': false, | ||
minimumDescriptionLength: 3, | ||
}, | ||
], | ||
}, | ||
}, | ||
{ | ||
files: ['**/*.md?(x)'], | ||
extends: [ | ||
'plugin:mdx/recommended', | ||
], | ||
parser: 'eslint-mdx', | ||
parserOptions: { | ||
markdownExtensions: ['*.md, *.mdx'], | ||
}, | ||
settings: { | ||
'mdx/code-blocks': false, | ||
'mdx/remark': true, | ||
}, | ||
rules: { | ||
'react/no-unescaped-entities': 0, | ||
} | ||
], | ||
}, | ||
} | ||
// markdown rules get configured in remarkrc.mjs | ||
}, | ||
], | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
// presets imports | ||
import remarkPresetLintRecommended from 'remark-preset-lint-consistent' | ||
import remarkPresetLintConsistent from 'remark-preset-lint-recommended' | ||
import remarkPresetLintMarkdownStyleGuide from 'remark-preset-lint-markdown-style-guide' | ||
|
||
// rules imports | ||
import remarkLintMaximumHeadingLength from 'remark-lint-maximum-heading-length' | ||
import remarkLintUnorderedListMarkerStyle from 'remark-lint-unordered-list-marker-style' | ||
import remarkLintNoUndefinedReferences from 'remark-lint-no-undefined-references' | ||
import remarkLintLinkTitleStyle from 'remark-lint-link-title-style' | ||
import remarkLintMaximumLineLength from 'remark-lint-maximum-line-length' | ||
import remarkLintListItemSpacing from 'remark-lint-list-item-spacing' | ||
|
||
const config = { | ||
plugins: [ | ||
// presets | ||
remarkPresetLintRecommended, | ||
remarkPresetLintConsistent, | ||
remarkPresetLintMarkdownStyleGuide, | ||
// rules | ||
// https://www.npmjs.com/package/remark-lint-maximum-heading-length | ||
[remarkLintMaximumHeadingLength, [1, 100]], | ||
// https://www.npmjs.com/package/remark-lint-unordered-list-marker-style | ||
[remarkLintUnorderedListMarkerStyle, 'consistent'], | ||
// https://www.npmjs.com/package/remark-lint-no-undefined-references | ||
[remarkLintNoUndefinedReferences, { allow: ['!NOTE', '!TIP', '!MORE', '!WARN', ' ', 'x'] }], | ||
// https://www.npmjs.com/package/remark-lint-link-title-style | ||
[remarkLintLinkTitleStyle, '\''], | ||
// https://www.npmjs.com/package/remark-lint-maximum-line-length | ||
[remarkLintMaximumLineLength, false], | ||
// https://www.npmjs.com/package/remark-lint-list-item-spacing | ||
[remarkLintListItemSpacing, false], | ||
] | ||
} | ||
|
||
export default config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,40 @@ | ||
{ | ||
"typescript.tsdk": "node_modules\\typescript\\lib", | ||
"typescript.enablePromptUseWorkspaceTsdk": true | ||
"typescript.tsdk": "node_modules\\typescript\\lib", | ||
"typescript.enablePromptUseWorkspaceTsdk": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": "never" | ||
}, | ||
"eslint.debug": true, | ||
"eslint.options": { | ||
"extensions": [ | ||
".js", | ||
".jsx", | ||
".md", | ||
".mdx", | ||
".ts", | ||
".tsx" | ||
] | ||
}, | ||
"eslint.validate": [ | ||
"markdown", | ||
"mdx", | ||
"javascript", | ||
"javascriptreact", | ||
"typescript", | ||
"typescriptreact" | ||
], | ||
"files.associations": { | ||
"*.mdx": "markdown" | ||
}, | ||
"eslint.onIgnoredFiles": "warn", | ||
"eslint.probe": [ | ||
"javascript", | ||
"javascriptreact", | ||
"typescript", | ||
"typescriptreact", | ||
"html", | ||
"vue", | ||
"markdown", | ||
"mdx" | ||
], | ||
} |
Oops, something went wrong.