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

Cannot compile ionic project with version 1.0.2/1.0.1 #50

Closed
webfrank opened this issue Feb 28, 2018 · 4 comments
Closed

Cannot compile ionic project with version 1.0.2/1.0.1 #50

webfrank opened this issue Feb 28, 2018 · 4 comments

Comments

@webfrank
Copy link

[17:23:31] typescript: node_modules/jsqr/dist/decoder/decodeData/index.d.ts, line: 6
Enum type 'Mode' has members with initializers that are not literals.

   L5:  export interface ByteChunk {
   L6:      type: Mode.Byte | Mode.Kanji;
   L7:      bytes: number[];

[17:23:31] typescript: node_modules/jsqr/dist/decoder/decodeData/index.d.ts, line: 6
Enum type 'Mode' has members with initializers that are not literals.

   L5:  export interface ByteChunk {
   L6:      type: Mode.Byte | Mode.Kanji;
   L7:      bytes: number[];

[17:23:31] typescript: node_modules/jsqr/dist/decoder/decodeData/index.d.ts, line: 16
In ambient enum declarations member initializer must be constant expression.

  L15:  export declare enum Mode {
  L16:      Numeric = "numeric",
  L17:      Alphanumeric = "alphanumeric",

[17:23:31] typescript: node_modules/jsqr/dist/decoder/decodeData/index.d.ts, line: 17
In ambient enum declarations member initializer must be constant expression.

  L16:  Numeric = "numeric",
  L17:  Alphanumeric = "alphanumeric",
  L18:  Byte = "byte",

[17:23:31] typescript: node_modules/jsqr/dist/decoder/decodeData/index.d.ts, line: 18
In ambient enum declarations member initializer must be constant expression.

  L17:  Alphanumeric = "alphanumeric",
  L18:  Byte = "byte",
  L19:  Kanji = "kanji",

[17:23:31] typescript: node_modules/jsqr/dist/decoder/decodeData/index.d.ts, line: 19
In ambient enum declarations member initializer must be constant expression.

  L18:      Byte = "byte",
  L19:      Kanji = "kanji",
@cozmo
Copy link
Owner

cozmo commented Feb 28, 2018

Quick question - What version of typescript are you using?

@webfrank
Copy link
Author

2.3 and cannot upgrade at this moment

@webfrank
Copy link
Author

webfrank commented Mar 2, 2018

Same error with 1.0.3 and I can confirm it happens with transpile enabled (production mode)

@webfrank
Copy link
Author

webfrank commented Mar 2, 2018

I managed to upgrade Ionic to use Typescript 2.4.2 and now it compiles without error. Probably worth to mention the package requires typescript >= 2.4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants