escape the slashes for webpack import

This commit is contained in:
Dan Ribbens
2020-04-08 20:08:24 -04:00
parent f7e72d28f7
commit 0dc84070c7
2 changed files with 2 additions and 3 deletions

View File

@@ -9,7 +9,6 @@ function stringify(obj) {
});
return `{${result.join(',')}}`;
}
return `React.lazy(() => import('${obj}'))`;
}
@@ -34,7 +33,7 @@ module.exports = function (config) {
const string = stringify({
...(allCollectionComponents || {}),
...(config.components || {}),
});
}).replace(/\\/g, '\\\\');
return {
code: `