Skip to content

Commit

Permalink
Add(Cross Import): onError handler
Browse files Browse the repository at this point in the history
  • Loading branch information
1aron committed Dec 25, 2023
1 parent 4cd3606 commit f43a69f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/cross-import/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ export default function crossImport(modulePath: string): any {
interopDefault: true,
cache: false,
debug: !!process.env.DEBUG,
onError(error) {
throw error
},
transform: (options) => {
if (process.env.DEBUG) {
console.log('[cross-import] jiti transform')
Expand Down

0 comments on commit f43a69f

Please sign in to comment.