TypeError: "exports" is read-only
See original GitHub issueWhen I try loading vue-pdf in my App.Vue file, I get an odd looking error:
import pdf from 'vue-pdf'
export default {
components: {
pdf
},
...
}
TypeError: "exports" is read-only
I don’t have jslint enabled. Any ideas as to what might be causing this? It’s preventing me from being able to use vue-pdf, which looks really cool.
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
TypeError: "exports" is read-only => When exporting a module ...
javascript - TypeError: "exports" is read-only => When exporting a module with method calling another method - Stack Overflow. Stack Overflow ...
Read more >Uncaught TypeError: "exports" is read-only · Issue #300 - GitHub
In vue-toastification/composition/nuxt/index.js the line module.exports = { useToast }; causes an error on page load. Uncaught TypeError: " ...
Read more >TypeError: "exports" is read-only - Get Help - Vue Forum
I have a vue project which I converted into a a library using vue ui so App.vue is the entry point. It created...
Read more >Uncaught TypeError - is read-only - MDBootstrap
Actual behavior Component is not working and giving Uncaught TypeError:"exports" is read-only in console. Resources (screenshots, code snippets etc.) ...
Read more >TypeError: "x" is read-only - JavaScript - MDN Web Docs
TypeError : "x" is read-only ... The JavaScript strict mode-only exception "is read-only" occurs when a global variable or object property that was...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
It compiles fine, so I only get these errors in the console at run time:
I tried to reproduce this error with webpack@2.3.3 without success. It seems that this error occurs when one mix esm (import/export) with CommonJS module (require/exports). Please give more details about the error (file/line number)