Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into useSlider
- Loading branch information
Showing
254 changed files
with
8,990 additions
and
4,330 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
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,25 @@ | ||
# Description | ||
|
||
<!-- Please include a summary of the change along with relevant motivation and context. --> | ||
|
||
|
||
## Type of change | ||
|
||
<!-- Check all relevant options. --> | ||
- [ ] Bug fix _(non-breaking change which fixes an issue)_ | ||
- [ ] New feature _(non-breaking change which adds functionality)_ | ||
- [ ] **Breaking change** _(fix or feature that would cause existing functionality to not work as before)_ | ||
|
||
# Checklist | ||
- [ ] Read the [Contributing Guide](https://github.com/streamich/react-use/blob/master/CONTRIBUTING.md) | ||
- [ ] Perform a code self-review | ||
- [ ] Comment the code, particularly in hard-to-understand areas | ||
- [ ] Add documentation | ||
- [ ] Add hook's story at Storybook | ||
- [ ] Cover changes with tests | ||
- [ ] Ensure the test suite passes (`yarn test`) | ||
- [ ] Provide 100% tests coverage | ||
- [ ] Make sure code lints (`yarn lint`). Fix it with `yarn lint:fix` in case of failure. | ||
- [ ] Make sure types are fine (`yarn lint:types`). | ||
|
||
<!-- If you can't check all the checkboxes right now - check what you can, create a Draft PR, make some changes if needed and get back to it when you will be able to put some marks in list. --> |
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,35 +1,39 @@ | ||
const path = require('path'); | ||
const {compilerOptions} = require('../tsconfig.json'); | ||
const { compilerOptions } = require('../tsconfig.json'); | ||
const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin'); | ||
|
||
const SRC_PATH = path.join(__dirname, '../src'); | ||
const basedir = path.join(__dirname, '..'); | ||
|
||
module.exports = { | ||
module: { | ||
rules: [ | ||
{ | ||
test: /\.md?$/, | ||
loader: "markdown-loader", | ||
}, | ||
{ | ||
test: /\.tsx?$/, | ||
loader: 'ts-loader', | ||
include: [ | ||
SRC_PATH, | ||
], | ||
options: { | ||
transpileOnly: true, // use transpileOnly mode to speed-up compilation | ||
compilerOptions: { | ||
...compilerOptions, | ||
declaration: false, | ||
}, | ||
module.exports = async ({ config, mode }) => { | ||
config.module.rules.push( | ||
{ | ||
test: /\.md?$/, | ||
loader: "markdown-loader", | ||
}, | ||
{ | ||
test: /\.tsx?$/, | ||
loader: 'ts-loader', | ||
include: [ | ||
path.join(basedir, 'src'), | ||
path.join(basedir, 'stories'), | ||
], | ||
options: { | ||
transpileOnly: true, // use transpileOnly mode to speed-up compilation | ||
compilerOptions: { | ||
...compilerOptions, | ||
declaration: false, | ||
}, | ||
} | ||
] | ||
}, | ||
resolve: { | ||
extensions: ['.ts', '.tsx', '.js', '.jsx'], | ||
enforceExtension: false | ||
}, | ||
plugins: [new ForkTsCheckerWebpackPlugin()], | ||
}, | ||
}, | ||
); | ||
|
||
config.plugins.push(new ForkTsCheckerWebpackPlugin()); | ||
|
||
config.resolve.extensions = ['.ts', '.tsx', '.js', '.jsx']; | ||
config.resolve.enforceExtension = false; | ||
|
||
// disable the hint about too big bundle | ||
config.performance.hints = false; | ||
|
||
return config; | ||
}; |
Oops, something went wrong.