Skip to content

Commit

Permalink
fix: adapt rspack 1.0.0-alpha (#94)
Browse files Browse the repository at this point in the history
  • Loading branch information
9aoy authored Jul 1, 2024
1 parent d313455 commit 26a2636
Show file tree
Hide file tree
Showing 25 changed files with 75 additions and 1 deletion.
3 changes: 3 additions & 0 deletions rsdoctor/arco-pro/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ const config = {
webSocketServer: 'sockjs',
historyApiFallback: true,
},
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
4 changes: 3 additions & 1 deletion rspack/basic-ts/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ const rspack = require('@rspack/core');
const config = {
entry: './src/index.ts',
resolve: {
tsConfigPath: path.resolve(__dirname, 'tsconfig.json'),
tsConfig: {
configFile: path.resolve(__dirname, 'tsconfig.json'),
},
extensions: ['...', '.ts'],
},
plugins: [
Expand Down
3 changes: 3 additions & 0 deletions rspack/builtin-swc-loader/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: './src/index.jsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.jsx'],
alias: {
Expand Down
3 changes: 3 additions & 0 deletions rspack/cra-ts/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: './src/index.tsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/cra/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: './src/index.jsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/loader-compat/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ const config = {
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
3 changes: 3 additions & 0 deletions rspack/postcss-loader/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ const config = {
entry: {
main: './src/index.js',
},
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
3 changes: 3 additions & 0 deletions rspack/preact/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: './src/index.jsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
alias: {
Expand Down
3 changes: 3 additions & 0 deletions rspack/react-15-classic/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ const config = {
entry: {
main: './src/index.jsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/react-15/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ const config = {
entry: {
main: './src/index.jsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/react-compiler-babel/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ const config = {
entry: {
main: './src/index.jsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/react-storybook/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ module.exports = {
entry: {
main: './src/main.jsx',
},
experiments: {
css: true,
},
plugins: [
new rspack.HtmlRspackPlugin({
template: './index.html',
Expand Down
3 changes: 3 additions & 0 deletions rspack/react-with-less/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ const config = {
entry: {
main: ['./src/index.jsx'],
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/react-with-sass/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: ['./src/index.jsx'],
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/react/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ const config = {
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
3 changes: 3 additions & 0 deletions rspack/solid/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: './src/index.jsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/svelte/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ const config = {
extensions: ['.mjs', '.js', '.ts', '.svelte'],
mainFields: ['svelte', 'browser', 'module', 'main'],
},
experiments: {
css: true,
},
output: {
path: path.join(__dirname, '/dist'),
filename: '[name].js',
Expand Down
3 changes: 3 additions & 0 deletions rspack/tailwind-jit/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: './src/index.js',
},
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
3 changes: 3 additions & 0 deletions rspack/tailwind/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ module.exports = {
entry: {
main: './src/index.js',
},
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
3 changes: 3 additions & 0 deletions rspack/treeshaking-transform-imports/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ const config = {
entry: {
main: './src/index.js',
},
experiments: {
css: true,
},
plugins: [new rspack.HtmlRspackPlugin()],
optimization: {
minimize: false,
Expand Down
3 changes: 3 additions & 0 deletions rspack/vanilla-extract-css/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ module.exports = {
extensions: ['.js', '.json', '.ts', '.tsx'],
},
devtool: 'source-map',
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
3 changes: 3 additions & 0 deletions rspack/vue/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ const config = {
entry: {
main: './src/main.js',
},
experiments: {
css: true,
},
devServer: {
historyApiFallback: true,
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/vue2/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ const config = {
entry: {
main: './src/main.js',
},
experiments: {
css: true,
},
devServer: {
historyApiFallback: true,
},
Expand Down
3 changes: 3 additions & 0 deletions rspack/vue3-jsx/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ const config = {
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
experiments: {
css: true,
},
module: {
rules: [
{
Expand Down
3 changes: 3 additions & 0 deletions rspack/vue3-tsx/rspack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ const config = {
entry: {
main: './src/main.tsx',
},
experiments: {
css: true,
},
resolve: {
extensions: ['...', '.ts', '.tsx', '.jsx'],
},
Expand Down

0 comments on commit 26a2636

Please sign in to comment.