mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-20 20:33:02 +00:00
docs: remove svelte-preprocess from svelte.config.js
This commit is contained in:
parent
38f98042f4
commit
a76f209b33
8 changed files with 284 additions and 304 deletions
|
@ -128,20 +128,18 @@ const NODE_ENV = process.env.NODE_ENV || "production";
|
|||
module.exports = {
|
||||
extensions: [".svelte", ".svx"],
|
||||
preprocess: [
|
||||
require("svelte-preprocess")({
|
||||
typescript: false,
|
||||
replace: [
|
||||
["process.env.VERSION", JSON.stringify(pkg.version)],
|
||||
["process.env.NODE_ENV", JSON.stringify(NODE_ENV)],
|
||||
],
|
||||
postcss: {
|
||||
plugins: [
|
||||
require("autoprefixer")({
|
||||
overrideBrowserslist: ["last 1 version", "ie >= 11"],
|
||||
}),
|
||||
],
|
||||
{
|
||||
markup: ({ filename, content }) => {
|
||||
if (/node_modules/.test(filename) || !filename.endsWith(".svelte"))
|
||||
return;
|
||||
return {
|
||||
code: content.replace(
|
||||
/process.env.VERSION/g,
|
||||
JSON.stringify(pkg.version)
|
||||
),
|
||||
};
|
||||
},
|
||||
}),
|
||||
},
|
||||
mdsvex({
|
||||
remarkPlugins: [plugin, slug, carbonify],
|
||||
layout: {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue