mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-16 22:10:13 +01:00
106 lines
1.6 KiB
JavaScript
106 lines
1.6 KiB
JavaScript
// @ts-check
|
|
|
|
"use strict";
|
|
|
|
const htmlEntry = "./exports-html.mjs";
|
|
const htmlName = "micromarkHtmlBrowser";
|
|
|
|
const base = {
|
|
"entry": "./exports.mjs",
|
|
"output": {
|
|
"path": __dirname
|
|
}
|
|
};
|
|
|
|
const commonjs = {
|
|
...base,
|
|
"output": {
|
|
...base.output,
|
|
"library": {
|
|
"type": "commonjs"
|
|
}
|
|
},
|
|
"target": "node"
|
|
};
|
|
|
|
const web = {
|
|
...base,
|
|
"output": {
|
|
...base.output,
|
|
"library": {
|
|
"name": "micromarkBrowser",
|
|
"type": "var"
|
|
}
|
|
},
|
|
"target": "web"
|
|
};
|
|
|
|
const production = {
|
|
"mode": "production"
|
|
};
|
|
|
|
const development = {
|
|
"devtool": false,
|
|
"mode": "development"
|
|
};
|
|
|
|
module.exports = [
|
|
{
|
|
...commonjs,
|
|
...production,
|
|
"output": {
|
|
...commonjs.output,
|
|
"filename": "micromark.cjs"
|
|
}
|
|
},
|
|
{
|
|
...commonjs,
|
|
...development,
|
|
"output": {
|
|
...commonjs.output,
|
|
"filename": "micromark.dev.cjs"
|
|
}
|
|
},
|
|
{
|
|
...web,
|
|
...production,
|
|
"output": {
|
|
...web.output,
|
|
"filename": "micromark-browser.js"
|
|
}
|
|
},
|
|
{
|
|
...web,
|
|
...development,
|
|
"output": {
|
|
...web.output,
|
|
"filename": "micromark-browser.dev.js"
|
|
}
|
|
},
|
|
{
|
|
...web,
|
|
...production,
|
|
"entry": htmlEntry,
|
|
"output": {
|
|
...web.output,
|
|
"library": {
|
|
...web.output.library,
|
|
"name": htmlName
|
|
},
|
|
"filename": "micromark-html-browser.js"
|
|
}
|
|
},
|
|
{
|
|
...web,
|
|
...development,
|
|
"entry": htmlEntry,
|
|
"output": {
|
|
...web.output,
|
|
"library": {
|
|
...web.output.library,
|
|
"name": htmlName
|
|
},
|
|
"filename": "micromark-html-browser.dev.js"
|
|
}
|
|
}
|
|
];
|