Download react-use/.storybook/webpack.config.js from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 990 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/react-use/.storybook/webpack.config.js
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset/react-use/.storybook/webpack.config.js
-
curl -L -o webpack.config.js https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/main/react-use/.storybook/webpack.config.js
990 Bytes
| const path = require('path'); | |
| const { compilerOptions } = require('../tsconfig.json'); | |
| const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin'); | |
| const basedir = path.join(__dirname, '..'); | |
| 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, | |
| }, | |
| }, | |
| }, | |
| ); | |
| 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; | |
| }; | |