Comments (4)
it should align:
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
// webpack.config.js
module.exports = {
entry: path.resolve(__dirname, "./index.js"),
module: {
rules: [{
test: /\.css$/,
use: [
MiniCssExtractPlugin.loader,
"css-loader",
{
loader: "postcss-loader",
options: {
postcssOptions: {
plugins: [{
postcssPlugin: 'tailwind-auto-import',
prepare() {
return {
Once: (root, {
AtRule
}) => {
const tailwindBase = new AtRule({
name: 'tailwind',
params: 'base',
});
root.prepend(tailwindBase);
}
}
}
},
require('tailwindcss')
]
}
}
}]
}],
},
plugins: [new MiniCssExtractPlugin()]
}
then npx webpack build
from rspack.
reduced:
// index.js
// nothing
// loader.js
class Node {
toJSON() {
throw Error('unreachable in webpack but it really did in rspack')
}
}
function loader(content, sourceMap) {
const nodes = [new Node()];
const callback = this.async();
callback(null, content, sourceMap, {
nodes
})
}
module.exports = loader
// rspack.config.js
module.exports = {
entry: "./index.js",
module: {
rules: [
{
test: /index\.js/,
use: [
{
loader: "./loader.js",
}
]
}
]
},
}
from rspack.
This issue arises from the communication between Rust and JavaScript. We need to retrieve the buffer in JavaScript and pass it to Rust. This situation might introduce some incompatibility into the webpack ecosystem.
from rspack.
Conclusion: pass ptr to rust and eval lazily
from rspack.
Related Issues (20)
- [Bug]: Trace does not work in parallel builds
- [Bug]: html template does not work as expected
- [Bug]: Can not read `loaderContext.data` when using pitch loader HOT 3
- [Bug]: `compilation.entrypoints.get()` have not chunks likes in webpack
- [Bug]: dev server error when hmr encounters a wasm package change. HOT 2
- [Bug]: CSS Class Name error. HOT 10
- [Bug]: Panic occurred at runtime. HOT 3
- [Feature]: Escape localIdentName file with dashes HOT 2
- [Bug]: Type error from @rspack/core/dist/config/zod.d.ts HOT 2
- [Bug]: Panic occured with rspack v0.6.4 HOT 1
- [Bug]: Panic occurred at runtime,using @rspack/[email protected] HOT 2
- [Bug]: after some build watches, memory crashes, as something leaks and grows in ram HOT 3
- [bug] pinyin-pro minify error HOT 1
- [Feature]: FormatJs plugin HOT 1
- [Bug]: missing plugin compliation hooks HOT 5
- [Feature]: 同步webpack.ProgressPlugin能力 HOT 1
- [docs] test guide HOT 2
- The type of `compilation.errors` changes to `any` after 0.6.4 HOT 3
- [Bug]: `import "binaryen"` throws error "'import.meta' cannot be used outside of module code" when minimize is on HOT 2
- [Bug]: react-router-dom cannot configure nested routers of 3 levels or more HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rspack.