Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SyntaxError: Unexpected token 'export' While test with Jest #400

Open
bschauhan opened this issue Jan 8, 2024 · 1 comment
Open

SyntaxError: Unexpected token 'export' While test with Jest #400

bschauhan opened this issue Jan 8, 2024 · 1 comment
Labels
pending:feedback This issue is blocked by necessary feedback.

Comments

@bschauhan
Copy link

bschauhan commented Jan 8, 2024

`/home/bharat/www/genera-monorepo/node_modules/@ckeditor/ckeditor5-watchdog/src/index.js:8
export { default as ContextWatchdog } from './contextwatchdog';
^^^^^^

SyntaxError: Unexpected token 'export'

   5 |   CommonModule,
   6 | } from '@angular/common';
>  7 | import {
     | ^
   8 |   CKEditorModule,
   9 | } from '@ckeditor/ckeditor5-angular';
  10 | import  DecoupledEditor  from '@ckeditor/ckeditor5-build-decoupled-document';

  at Runtime.createScriptFromCode (../../node_modules/jest-runtime/build/index.js:1495:14)
  at Object.<anonymous> (../../node_modules/@ckeditor/ckeditor5-angular/fesm2015/ckeditor-ckeditor5-angular.mjs:4:32)
  at Object.<anonymous> (src/lib/title-text-editor/title-text-editor.component.ts:7:1)
  at Object.<anonymous> (src/lib/title-text-editor/title-text-editor.component.spec.ts:4:1)`
@Witoso
Copy link
Member

Witoso commented Jan 9, 2024

Hi! Please provide some reproducible samples that we could use. Our code uses ESM syntax, make sure that Jest understands it.

@Witoso Witoso added the pending:feedback This issue is blocked by necessary feedback. label Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pending:feedback This issue is blocked by necessary feedback.
Projects
None yet
Development

No branches or pull requests

2 participants