Bug with files.associations config and SFC script tags
See original GitHub issueSimilar to an older issue which was complaining about <template>
tags in a SFC under a file association.
https://github.com/vuejs/vetur/issues/1480
Info
- Platform: Linux
- Vetur version:
0.31.3
- VS Code version:
1.52.0
Problem
"files.associations": {
"*.foo": "vue"
},
<script>
</script>
<template>
</template>
Fails with: "Cannot find name 'script'"
Whereas the following succeeds:
<script lang="js">
</script>
<template>
</template>
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Bug with files.associations config and SFC script tags ... - Issuehunt
We don't support files.associations . We have a lot of judgment based on file names. Vetur provide TypeScript/JavaScript feature with TypeScript language ...
Read more >use files.associations config, Vetur version >= 0.22.5 has error
I'm convinced this is a bug. In any file type associated with Vue. A <script> tag should be interpreted as Javascript unless otherwise...
Read more >This file does not have a program associated with it ... - TechNet
When i open any app that has to do with a setting ex. "Display Settings", it just says "ms-settting:display This file does not...
Read more >Windows 10 bug corrupts your hard drive on seeing this file's ...
In multiple tests by BleepingComputer, this one-liner can be delivered hidden inside a Windows shortcut file, a ZIP archive, batch files, ...
Read more >MS Edge browser hijacking PDF file association - Super User
in upper right Settings Cookies and site permissions PDF documents Set Always open PDF files externally to ON.
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 FreeTop 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
Top GitHub Comments
We don’t support
files.associations
. We have a lot of judgment based on file names. Vetur provide TypeScript/JavaScript feature with TypeScript language service. TypeScript language service don’t support custom filename extension.If you want to support this option, you need a lot of energy. I don’t think we have enough development energy to do this.
The more I understand how this handles extensions and custom blocks, the more I’m convinced this is a bug.
*.foo
will be scanned and<script lang="js">
will correctly be parsed.*.foo
will be scanned and<script>
will not be found. (Or rather it will be found but Vetur will complain about not knowing “script” blocks)If it can find one. Why does it not find the other?