draft: refactor project so it sits on top of a standalone app
This commit is contained in:
+28
@@ -0,0 +1,28 @@
|
||||
"use strict";
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.default = void 0;
|
||||
|
||||
function getDefaultSassImplementation() {
|
||||
let sassImplPkg = 'node-sass';
|
||||
|
||||
try {
|
||||
require.resolve('node-sass');
|
||||
} catch (error) {
|
||||
try {
|
||||
require.resolve('sass');
|
||||
|
||||
sassImplPkg = 'sass';
|
||||
} catch (ignoreError) {
|
||||
sassImplPkg = 'node-sass';
|
||||
}
|
||||
} // eslint-disable-next-line import/no-dynamic-require, global-require
|
||||
|
||||
|
||||
return require(sassImplPkg);
|
||||
}
|
||||
|
||||
var _default = getDefaultSassImplementation;
|
||||
exports.default = _default;
|
||||
Reference in New Issue
Block a user