mirror of
https://github.com/youzan/vant.git
synced 2025-10-17 16:44:21 +00:00
chore: temporarily comment some code
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import * as compiler from 'vue-template-compiler';
|
||||
import * as compiler from '@vue/compiler-sfc';
|
||||
import * as compileUtils from '@vue/component-compiler-utils';
|
||||
import hash from 'hash-sum';
|
||||
import { parse } from 'path';
|
||||
@@ -87,7 +87,7 @@ export async function compileSfc(filePath: string): Promise<any> {
|
||||
const descriptor = parseSfc(filePath);
|
||||
const { template, styles } = descriptor;
|
||||
|
||||
const hasScoped = styles.some(s => s.scoped);
|
||||
const hasScoped = styles.some((s) => s.scoped);
|
||||
const scopeId = hasScoped ? `data-v-${hash(source)}` : '';
|
||||
|
||||
// compile js part
|
||||
@@ -107,9 +107,7 @@ export async function compileSfc(filePath: string): Promise<any> {
|
||||
}
|
||||
|
||||
writeFileSync(jsFilePath, script);
|
||||
compileJs(jsFilePath)
|
||||
.then(resolve)
|
||||
.catch(reject);
|
||||
compileJs(jsFilePath).then(resolve).catch(reject);
|
||||
})
|
||||
);
|
||||
}
|
||||
|
@@ -1,6 +1,6 @@
|
||||
import Vue from 'vue';
|
||||
// import Vue from 'vue';
|
||||
import 'jest-canvas-mock';
|
||||
// @ts-ignore
|
||||
import Package from '../../dist/package-entry';
|
||||
// import Package from '../../dist/package-entry';
|
||||
|
||||
Vue.use(Package);
|
||||
// Vue.use(Package);
|
||||
|
@@ -40,26 +40,26 @@ const plugins = [
|
||||
}),
|
||||
];
|
||||
|
||||
const tsconfigPath = join(CWD, 'tsconfig.json');
|
||||
if (existsSync(tsconfigPath)) {
|
||||
const ForkTsCheckerPlugin = require('fork-ts-checker-webpack-plugin');
|
||||
plugins.push(
|
||||
new ForkTsCheckerPlugin({
|
||||
formatter: 'codeframe',
|
||||
vue: { enabled: true },
|
||||
logger: {
|
||||
// skip info message
|
||||
info() {},
|
||||
warn(message: string) {
|
||||
consola.warn(message);
|
||||
},
|
||||
error(message: string) {
|
||||
consola.error(message);
|
||||
},
|
||||
},
|
||||
})
|
||||
);
|
||||
}
|
||||
// const tsconfigPath = join(CWD, 'tsconfig.json');
|
||||
// if (existsSync(tsconfigPath)) {
|
||||
// const ForkTsCheckerPlugin = require('fork-ts-checker-webpack-plugin');
|
||||
// plugins.push(
|
||||
// new ForkTsCheckerPlugin({
|
||||
// formatter: 'codeframe',
|
||||
// vue: { enabled: true },
|
||||
// logger: {
|
||||
// // skip info message
|
||||
// info() {},
|
||||
// warn(message: string) {
|
||||
// consola.warn(message);
|
||||
// },
|
||||
// error(message: string) {
|
||||
// consola.error(message);
|
||||
// },
|
||||
// },
|
||||
// })
|
||||
// );
|
||||
// }
|
||||
|
||||
export const baseConfig = {
|
||||
mode: 'development',
|
||||
@@ -112,7 +112,7 @@ export const baseConfig = {
|
||||
},
|
||||
{
|
||||
test: /\.md$/,
|
||||
use: [CACHE_LOADER, 'vue-loader', '@vant/markdown-loader'],
|
||||
use: [CACHE_LOADER, '@vant/markdown-loader'],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
Reference in New Issue
Block a user