dumi 2.4.0-alpha.14 → 2.4.0-alpha.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -136,6 +136,10 @@ var getLoadHook = (api) => {
|
|
|
136
136
|
return await customRunLoaders({
|
|
137
137
|
resource: filePath,
|
|
138
138
|
loaders: [
|
|
139
|
+
{
|
|
140
|
+
loader: require.resolve("../../loaders/post-raw"),
|
|
141
|
+
options: {}
|
|
142
|
+
},
|
|
139
143
|
{
|
|
140
144
|
loader: require.resolve("raw-loader"),
|
|
141
145
|
options: {}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
|
|
19
|
+
// src/loaders/post-raw/index.ts
|
|
20
|
+
var post_raw_exports = {};
|
|
21
|
+
__export(post_raw_exports, {
|
|
22
|
+
default: () => postRawLoader
|
|
23
|
+
});
|
|
24
|
+
module.exports = __toCommonJS(post_raw_exports);
|
|
25
|
+
function postRawLoader(raw) {
|
|
26
|
+
return `
|
|
27
|
+
import '${this.resourcePath}?watch=parent';
|
|
28
|
+
${raw};
|
|
29
|
+
`;
|
|
30
|
+
}
|