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
ref type error #2
Comments
Sorry I missed your second question, I did not use vue class, can you provide a piece of code that can reproduce the error? |
<template>
<div >
{{foo}} Cannot find name 'foo'.ts(2304)
</div>
</template>
<script lang="ts">
import { Vue, Component } from "vue-property-decorator";
@Component
export default class extends Vue {
private foo = 1;
}
</script> BTW, Vue-html has a problem with comments. It now behaves like JS It's not easy for vue2.x to have good type intellisense, but it works well with your plugin and @vue/composition-api. |
Allowing access to private properties requires some hacking works, I am not sure if I should do this. If private properties are to be made public, how to control which properties are not accessible in interpolations? |
This may require you to do something special with the vue-class, because in vue-class, even private properties are eventually merged into data,methods... In vetur, no errors are reported Vutur has become unbearably slow, which is why I'm giving it up for now If use vue2.x, need to write extra type files, but in the end it will have good TS support |
Oh cool, I am glad to hear that you use vue2 smoothly! And I can understand your "unbearably" feeling. :( Can you talk about the purpose of using "private" for class properties? |
If i write my own project, i will avoid this problem. However, in teamwork, other members may write private properties. I recommended this extension to a friend. He didn't use it because of this Now I feel sad that it can't import the definitions of other files very well, even if the file where the variable to be imported is already written |
I don't quite understand the import issue you mentioned, and I want to ask some questions about the private properties problem. Can you contact me with discord? My id is johnsoncodehk. Thanks |
cereschen#9837 my id |
Oh don't know need the tag! Please pass my application. |
was there any ways to resolve this issue? The team project I'm working on also has a ton of a |
@ghiscoding I did't found out a solution yet, nice to have a issue for track. |
it would be nice to have a solution in the future, did u wanted a new issue or just keep this issue, and perhaps reopen it? |
@ghiscoding this issue is different problem actually, so please open a new if you want to track. |
:ref="'music'"
is okand Seems like miss the type file in node_modules while find something to import?
In Vue-class files, private property will report an error
Private keyword doesn't do anything, but a lot of people get used to writing it
It's nice to see that you're still maintaining the project, and it's now much faster than Vetur
The text was updated successfully, but these errors were encountered: