Skip to content

Commit

Permalink
fix(core): soft require engine options
Browse files Browse the repository at this point in the history
  • Loading branch information
antfu committed Jan 20, 2025
1 parent 613d35b commit 10a6f78
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/core/src/constructors/internal.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export async function createShikiInternal(options: HighlighterCoreOptions): Prom
warnDeprecated('`loadWasm` option is deprecated. Use `engine: createOnigurumaEngine(loadWasm)` instead.')
}
if (!options.engine) {
throw new Error('`engine` option is required.')
warnDeprecated('`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.')
}

const [
Expand Down

0 comments on commit 10a6f78

Please sign in to comment.