question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

BUG | v6.1.0 | An accessor cannot be declared in an ambient context

See original GitHub issue
Bug Report or Feature Request (mark with an x)
- [ x ] Regression (a behavior that used to work and stopped working in a new release)
- [ x ] Bug report -> please search issues before submitting
- [ ] Feature request
- [ ] Documentation issue or request

When building on latest (v6.1.0) I get the following error. Once reverting back to v6.0.2 I no longer get this error.

ERROR in ../node_modules/ng2-pdf-viewer/src/app/pdf-viewer/pdf-viewer.component.d.ts:51 - error An accessor cannot be declared in an ambient context.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:9
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

5reactions
VadimDezcommented, Feb 12, 2020

So it seems like there’s a breaking change in the typescript library. After the upgrade to Angular 9, Typescript was updated to the lates version (3.7), which seems to be incompatible with version 3.5. Try to stick with 6.0.2 of ng2-pdf-viewer in your project for now

1reaction
VadimDezcommented, Feb 25, 2020

Can you please try out the 6.1.1 version?

Read more comments on GitHub >

github_iconTop Results From Across the Web

TS1086: An accessor cannot be declared in ambient context
TS1086: An accessor cannot be declared in ambient context ... Does somebody know a reason? I can't test my app until I fix...
Read more >
Angular 7 (An accessor cannot be declared in an ambient ...
Hello. I'm quite new to Angular and when I try to build --prod my angular apps, I get this errors: ERROR in ...
Read more >
@kolkov/angular-editor - npm Package Health Analysis | Snyk
Based on project statistics from the GitHub repository for the npm package @kolkov/angular-editor, we found that it has been starred 590 times, and...
Read more >
ng2-idle - Bountysource
[x ] bug report => search github for a similar issue or PR before submitting [ ] feature request ... An accessor cannot...
Read more >
Overview - TypeScript
get and set Accessors Are Allowed in Ambient Contexts ... But non-module global scripts cannot access types declared in modules. Enter import types....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found