Skip to content

Commit

Permalink
修复打包入口ts问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Yin-Jinlong committed Apr 17, 2024
1 parent 8e09284 commit ce9b4ba
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/.press/plugin/press/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,16 +74,16 @@ ${setupFile ? `setup(app).then(()=>{
resolveId(source, importer, options) {
if (source.endsWith('index.html')) {
return source.replace(/\\/g, '/')
} else if (source === '/main.ts?press')
return source.substring(1)
} else if (source.endsWith('main.ts?press'))
return source
if (!isVueMd(source))
return
return source
},
load(id, options) {
if (relative('.', id) === 'index.html')
return INDEX_HTML
if (id === 'main.ts?press') {
if (id.endsWith('main.ts?press')) {
return MAIN_TS
}
if (!isVueMd(id))
Expand Down

0 comments on commit ce9b4ba

Please sign in to comment.