Skip to content

Commit

Permalink
chore: 删除无用代码
Browse files Browse the repository at this point in the history
  • Loading branch information
Jinbao1001 committed May 22, 2024
1 parent 0263e3b commit b10da8e
Show file tree
Hide file tree
Showing 6 changed files with 2 additions and 11 deletions.
3 changes: 0 additions & 3 deletions .dumirc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ import { version } from './package.json';
export default defineConfig({
html2sketch: {},
mfsu: false,
// manifest: {
// fileName: "build-manifest.json"
// },
favicons: [
'https://gw.alipayobjects.com/zos/bmw-prod/d3e3eb39-1cd7-4aa5-827c-877deced6b7e/lalxt4g3_w256_h256.png',
],
Expand Down
2 changes: 1 addition & 1 deletion docs/config/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ dumi 内置了站点统计的功能,目前支持 [Google Analytics](https://an

<img src="https://gw.alipayobjects.com/zos/bmw-prod/0b8bbca9-e642-4964-bdeb-841d2b57dd21/leibpn7e_w1024_h686.gif" width="768" />

光看演示不过瘾?不妨试试看 1
光看演示不过瘾?不妨试试看:

```jsx
export default () => (
Expand Down
2 changes: 0 additions & 2 deletions src/client/theme-api/useSiteSearch/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
import { useNavData } from 'dumi';
import { useCallback, useEffect, useRef, useState } from 'react';
// @ts-ignore
// x-todo
// import workerCode from '-!../../../../compiled/_internal/searchWorker.min?dumi-raw';
import workerCode from '../../../../compiled/_internal/searchWorker.min?dumi-raw';
import useSearchData from './useSearchData';

Expand Down
1 change: 0 additions & 1 deletion src/features/compile/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ export default (api: IApi) => {
return acc;
}, []),
);
// mako不走 ssr要走 正常要走

// configure loader to compile markdown
api.modifyConfig((memo) => {
Expand Down
2 changes: 0 additions & 2 deletions src/loaders/markdown/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,10 +169,8 @@ export const demos = {
if (asset.dependencies[file]?.type === 'FILE') {
// to avoid modify original asset object
asset = lodash.cloneDeep(asset);
// x-todo
asset.dependencies[
file
// ].value = `{{{require('-!${resolveMap[file]}?dumi-raw').default}}}`;
].value = `{{{require('${resolveMap[file]}?dumi-raw').default}}}`;
}
});
Expand Down
3 changes: 1 addition & 2 deletions src/templates/meta/exports.ts.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ export function getRouteMetaById<T extends { syncOnly?: boolean }>(
* get all routes meta
*/
export async function getFullRoutesMeta(): Promise<Record<string, IRouteMeta>> {
const a = await Promise.all(
return await Promise.all(
Object.keys(filesMeta).map(async (id) => ({
id,
meta: await getRouteMetaById(id),
Expand All @@ -194,5 +194,4 @@ export async function getFullRoutesMeta(): Promise<Record<string, IRouteMeta>> {
{},
),
);
return a
}

0 comments on commit b10da8e

Please sign in to comment.