@@ -17,7 +17,7 @@ import GridStatusBar from '~/components/grid/StatusBar.vue';
1717import GridCoverTooltip from ' ~/components/grid/CoverTooltip.vue' ;
1818import { AG_GRID_LOCALE_CN } from ' @ag-grid-community/locale' ;
1919import { type Info } from ' ~/store/v2/info' ;
20- import { getArticleCache , articleDeleted } from ' ~/store/v2/article' ;
20+ import { getArticleCache , articleDeleted , getArticleByLink } from ' ~/store/v2/article' ;
2121import type { AppMsgEx } from ' ~/types/types' ;
2222import { formatElapsedTime , formatTimeStamp , sleep , ITEM_SHOW_TYPE , durationToSeconds } from ' ~/utils' ;
2323import { Downloader } from ' ~/utils/download/Downloader' ;
@@ -27,9 +27,9 @@ import { getCommentCache } from '~/store/v2/comment';
2727import type { ArticleMetadata , DownloaderStatus , ExporterStatus } from ' ~/utils/download/types' ;
2828import { getMetadataCache , type Metadata } from ' ~/store/v2/metadata' ;
2929import type { PreviewArticle } from ' #components' ;
30- import TurndownService from ' turndown' ;
3130import type { Preferences } from ' ~/types/preferences' ;
3231import AccountSelectorForArticle from ' ~/components/selector/AccountSelectorForArticle.vue' ;
32+ import { isDev } from ' ~/config' ;
3333
3434let globalRowData: Article [] = [];
3535
@@ -386,7 +386,6 @@ function onFilterChanged(event: FilterChangedEvent) {
386386 event .api .deselectAll ();
387387}
388388
389- const isDev = ! import .meta .env .PROD ;
390389const preferences = usePreferences ();
391390const hideDeleted = computed (() => (preferences .value as unknown as Preferences ).hideDeleted );
392391
@@ -962,9 +961,8 @@ async function export2word() {
962961}
963962
964963async function debug() {
965- const turndownService = new TurndownService ();
966- const markdown = turndownService .turndown (' <h1>Hello world!</h1>' );
967- console .debug (markdown );
964+ const article = await getArticleByLink (' https://mp.weixin.qq.com/s/8sCrH6AZyyff5dVXQAzVFQ' );
965+ console .log (article );
968966}
969967 </script >
970968
0 commit comments