Skip to content

Commit

Permalink
feat: expose rewriteImports (#104)
Browse files Browse the repository at this point in the history
  • Loading branch information
pikax authored May 9, 2020
1 parent 49e79e7 commit d6151bf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/node/server/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import { assetPathPlugin } from './serverPluginAssets'
import { esbuildPlugin } from './serverPluginEsbuild'

export { Resolver }
export { rewriteImports } from './serverPluginModuleRewrite'

export type Plugin = (ctx: PluginContext) => void

Expand Down
2 changes: 1 addition & 1 deletion src/node/server/serverPluginModuleRewrite.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ export const moduleRewritePlugin: Plugin = ({ app, watcher, resolver }) => {
})
}

function rewriteImports(
export function rewriteImports(
source: string,
importer: string,
resolver: InternalResolver,
Expand Down

0 comments on commit d6151bf

Please sign in to comment.