-
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
301 changed files
with
22,841 additions
and
21,263 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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
**/svgs/**/*.tsx | ||
out |
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,15 +1,68 @@ | ||
/* eslint-env node */ | ||
module.exports = { | ||
extends: [ | ||
"eslint:recommended", | ||
"plugin:@typescript-eslint/recommended", | ||
// @todo | ||
// "plugin:@typescript-eslint/recommended-type-checked", | ||
"next/core-web-vitals", | ||
"next/typescript", | ||
"eslint-config-prettier", | ||
], | ||
overrides: [ | ||
{ | ||
files: ["*.js", "*.cjs", "*.mjs"], | ||
extends: ["plugin:@typescript-eslint/disable-type-checked"], | ||
}, | ||
], | ||
parser: "@typescript-eslint/parser", | ||
root: true, | ||
extends: ["@react-native-community/eslint-config", "eslint-config-prettier"], | ||
rules: { | ||
"prettier/prettier": 0, | ||
// not interesting for rescript generated js | ||
"no-bitwise": 0, | ||
"no-shadow": 0, | ||
"no-unused-vars": 0, | ||
"no-useless-escape": 0, | ||
parserOptions: { | ||
project: true, | ||
tsconfigRootDir: __dirname, | ||
}, | ||
env: { | ||
"jest/globals": true, | ||
plugins: [ | ||
"@typescript-eslint", | ||
"eslint-plugin-import", | ||
"eslint-plugin-unused-imports", | ||
], | ||
rules: { | ||
// not relevant with some switch/case usage | ||
"no-fallthrough": "off", | ||
|
||
// that's for escape hatch, why would we want to ban it? | ||
"@typescript-eslint/ban-ts-comment": "off", | ||
|
||
// handy sometimes | ||
"@typescript-eslint/no-explicit-any": "off", | ||
|
||
"sort-imports": [ | ||
"error", | ||
{ | ||
ignoreCase: true, | ||
ignoreDeclarationSort: true, | ||
}, | ||
], | ||
"import/order": [ | ||
"error", | ||
{ | ||
alphabetize: { | ||
order: "asc", | ||
caseInsensitive: true, | ||
}, | ||
"newlines-between": "always", | ||
}, | ||
], | ||
|
||
"unused-imports/no-unused-imports": "error", | ||
"unused-imports/no-unused-vars": [ | ||
"warn", | ||
{ | ||
vars: "all", | ||
varsIgnorePattern: "^_", | ||
args: "after-used", | ||
argsIgnorePattern: "^_", | ||
}, | ||
], | ||
}, | ||
}; |
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 |
---|---|---|
@@ -1,4 +1 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
lint-staged | ||
npm test |
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 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
npm test |
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 +1 @@ | ||
16 | ||
22 |
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,11 +1,14 @@ | ||
{ | ||
"javascript.validate.enable": false, | ||
"typescript.format.enable": false, | ||
"typescript.validate.enable": false, | ||
"flow.useBundledFlow": false, | ||
"eslint.enable": true, | ||
"triggerTaskOnSave.tasks": { | ||
"eslint-rescript": ["src/**/*.res"] | ||
"search.exclude": { | ||
"**/node_modules": true, | ||
"**/.next": true | ||
}, | ||
"triggerTaskOnSave.delay": 1000 | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": "explicit" | ||
}, | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true, | ||
"eslint.validate": ["javascript"], | ||
"typescript.preferences.importModuleSpecifier": "non-relative", | ||
"typescript.tsserver.experimental.enableProjectDiagnostics": true | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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,52 @@ | ||
import type { NextConfig } from "next"; | ||
import packageJson from "./package.json" with { type: "json" }; | ||
|
||
const transpilePackages = [ | ||
// react-native packages | ||
"react-native", | ||
...Object.keys(packageJson.dependencies).filter( | ||
(dep) => dep.startsWith("react-native") || dep.startsWith("@react-native") | ||
), | ||
]; | ||
const nextConfig: NextConfig = { | ||
experimental: { | ||
turbo: { | ||
rules: { | ||
"*.js": { | ||
loaders: [ | ||
{ | ||
loader: "string-replace-loader", | ||
options: { | ||
search: "__DEV__", | ||
replace: | ||
process.env.NODE_ENV !== "production" ? "true" : "false", | ||
}, | ||
}, | ||
], | ||
}, | ||
}, | ||
resolveAlias: { | ||
"react-native": "react-native-web", | ||
}, | ||
resolveExtensions: [ | ||
".web.tsx", | ||
".web.ts", | ||
".web.jsx", | ||
".web.js", | ||
".tsx", | ||
".ts", | ||
".jsx", | ||
".js", | ||
".mjs", | ||
".json", | ||
], | ||
}, | ||
}, | ||
transpilePackages, | ||
|
||
env: { | ||
ENV: process.env.NODE_ENV, | ||
}, | ||
}; | ||
|
||
export default nextConfig; |
Oops, something went wrong.