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

three 0.111+ / TS1086: An accessor cannot be declared in an ambient context. #161

Closed
makimenko opened this issue Dec 27, 2019 · 3 comments
Closed
Labels
blocked-upstream Change/update blocked due to a dependency which requries the old version.

Comments

@makimenko
Copy link
Owner

Steps

  1. Upgrade dependency: three 0.112
  2. Build library

Actual Result

TS1086: An accessor cannot be declared in an ambient context.

Expected Result

No failure

makimenko added a commit that referenced this issue Dec 27, 2019
- Upgrade to Typescript 3.7.4 + workarounds
- angularCompilerOptions.disableTypeScriptVersionCheck=true
- added polyfills.ts: __importDefault
@makimenko
Copy link
Owner Author

makimenko commented Dec 27, 2019

The problem is that threejs requires newer Typescript 3.7+ which is not supported by Angular yet.

As workaround:

  • Upgrade to Typescript 3.7.4
  • angularCompilerOptions.disableTypeScriptVersionCheck=true
  • added polyfills.ts: __importDefault
  • added __importDefault to test.ts

in scope of commits: d319384 and 3646678

Proper fix:

makimenko added a commit that referenced this issue Dec 27, 2019
- Upgrade to Typescript 3.7.4 + workarounds
- angularCompilerOptions.disableTypeScriptVersionCheck=true
- added polyfills.ts: __importDefault
@makimenko
Copy link
Owner Author

@makimenko makimenko added the blocked-upstream Change/update blocked due to a dependency which requries the old version. label Jan 6, 2020
@makimenko makimenko changed the title TS1086: An accessor cannot be declared in an ambient context. three 0.111+ / TS1086: An accessor cannot be declared in an ambient context. Jan 7, 2020
makimenko added a commit that referenced this issue Jan 31, 2020
- upgraded to three 0.133.2
- Switched to Angular CLI 9.0.0-rc.12 (to be verified)
- Removed workaround: `angularCompilerOptions.disableTypeScriptVersionCheck=true`

The rest workarounds left:
- added polyfills.ts: __importDefault
- added __importDefault to test.ts
makimenko added a commit that referenced this issue Jan 31, 2020
@makimenko
Copy link
Owner Author

makimenko commented Jan 31, 2020

  • upgraded to three 0.113.2
  • Switched to Angular CLI 9.0.0-rc.12 (to be verified)
  • Removed workaround: angularCompilerOptions.disableTypeScriptVersionCheck=true

The rest workarounds left:

  • added polyfills.ts: __importDefault
  • added __importDefault to test.ts

makimenko added a commit that referenced this issue Feb 8, 2020
#161 remove temporary workarounds in polyfils
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked-upstream Change/update blocked due to a dependency which requries the old version.
Projects
None yet
Development

No branches or pull requests

1 participant