-
Notifications
You must be signed in to change notification settings - Fork 3
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
16 changed files
with
6,291 additions
and
5,451 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,21 @@ | ||
|
||
# See https://help.github.com/ignore-files/ for more about ignoring files. | ||
|
||
# dependencies | ||
node_modules | ||
|
||
# builds | ||
build | ||
.rpt2_cache | ||
|
||
# misc | ||
.DS_Store | ||
.env | ||
.env.local | ||
.env.development.local | ||
.env.test.local | ||
.env.production.local | ||
|
||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* |
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,55 @@ | ||
module.exports = { | ||
env: { | ||
browser: true, | ||
es6: true, | ||
node: true, | ||
}, | ||
settings: { | ||
"import/resolver": { | ||
node: { | ||
paths: ["src"], | ||
extensions: [ | ||
".js", | ||
".ts", | ||
".jsx", | ||
".tsx", | ||
], | ||
}, | ||
}, | ||
}, | ||
extends: [ | ||
"plugin:react-hooks/recommended", | ||
"plugin:react/recommended", | ||
"airbnb", | ||
], | ||
globals: { | ||
Atomics: "readonly", | ||
SharedArrayBuffer: "readonly", | ||
}, | ||
parser: "@typescript-eslint/parser", | ||
parserOptions: { | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
ecmaVersion: 2018, | ||
sourceType: "module", | ||
}, | ||
plugins: [ | ||
"react", | ||
"react-hooks", | ||
"@typescript-eslint", | ||
], | ||
rules: { | ||
"react/jsx-filename-extension": [1, { "extensions": [".tsx", ".jsx"] }], | ||
"react/jsx-props-no-spreading": 0, | ||
"import/prefer-default-export": 0, | ||
"import/extensions": 0, | ||
"no-unused-vars": 0, | ||
"react-hooks/exhaustive-deps": "warn", | ||
"react-hooks/rules-of-hooks": "error", | ||
"jsx-a11y/no-static-element-interactions": 0, | ||
"jsx-a11y/click-events-have-key-events": 0, | ||
"jsx-a11y/label-has-associated-control": 0, | ||
"dot-notation": 0, | ||
}, | ||
}; |
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,6 @@ | ||
{ | ||
"eslint.workingDirectories": [ | ||
"./src/", | ||
"./", | ||
] | ||
} |
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,32 +1,50 @@ | ||
import babel from 'rollup-plugin-babel' | ||
import commonjs from 'rollup-plugin-commonjs' | ||
import external from 'rollup-plugin-peer-deps-external' | ||
import resolve from 'rollup-plugin-node-resolve' | ||
import url from 'rollup-plugin-url' | ||
import typescript from 'rollup-plugin-typescript2'; | ||
import commonjs from 'rollup-plugin-commonjs'; | ||
import external from 'rollup-plugin-peer-deps-external'; | ||
// import postcss from 'rollup-plugin-postcss-modules'; | ||
import postcss from 'rollup-plugin-postcss'; | ||
import resolve from 'rollup-plugin-node-resolve'; | ||
import url from 'rollup-plugin-url'; | ||
import svgr from '@svgr/rollup'; | ||
|
||
import pkg from './package.json' | ||
import pkg from './package.json'; | ||
|
||
export default { | ||
input: 'src/index.js', | ||
input: 'src/index.ts', | ||
output: [ | ||
{ | ||
file: pkg.main, | ||
format: 'cjs', | ||
sourcemap: true | ||
exports: 'named', | ||
sourcemap: true, | ||
}, | ||
{ | ||
file: pkg.module, | ||
format: 'es', | ||
sourcemap: true | ||
} | ||
exports: 'named', | ||
sourcemap: true, | ||
}, | ||
], | ||
plugins: [ | ||
external(), | ||
url({ exclude: ['**/*.svg'] }), | ||
babel({ | ||
exclude: 'node_modules/**' | ||
postcss({ | ||
modules: true, | ||
}), | ||
url(), | ||
svgr(), | ||
resolve(), | ||
commonjs() | ||
] | ||
} | ||
typescript({ | ||
rollupCommonJSResolveHack: true, | ||
clean: true, | ||
}), | ||
commonjs({ | ||
include: 'node_modules/**', | ||
namedExports: { | ||
// left-hand side can be an absolute path, a path | ||
// relative to the current directory, or the name | ||
// of a module in node_modules | ||
scheduler: ['unstable_runWithPriority', 'LowPriority'], | ||
}, | ||
}), | ||
], | ||
}; |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
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,14 @@ | ||
/** | ||
* Options for useWindowSize hook. | ||
*/ | ||
export interface UseWindowSizeOptions { | ||
useDebounce?: boolean; | ||
debounceTimeMs?: number; | ||
} | ||
|
||
/** | ||
* Options for parseLayoutResult. | ||
*/ | ||
export interface ParseLayoutResultOptions { | ||
width: number | ||
} |
File renamed without changes.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.