-
Notifications
You must be signed in to change notification settings - Fork 12
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
Error parsing empty component #9
Comments
@aschempp How can this be recreated? The CLI tool should not even show components that don't have any strings in them to be translated. |
I fixed a bug in |
Thanks for the update! Now I get a slightly different message:
The component is rather simple, here's what it looks like: <template>
<div id="app">
<error v-if="$store.state.error"/>
<router-view v-else/>
</div>
</template>
<script>
// import "../../template/lib/jquery/jquery.js";
// import "../../template/lib/popper.js/popper.js";
// import "../../template/lib/bootstrap/js/bootstrap.js";
import Error from './layouts/Error';
export default {
components: { Error },
created() {
this.$store.dispatch('auth/refresh');
},
};
</script>
<style rel="stylesheet/scss" lang="scss">
@import "../assets/template/lib/perfect-scrollbar/css/perfect-scrollbar.css";
@import "../assets/template/lib/jquery.steps/jquery.steps.css";
@import "../assets/template/lib/SpinKit/spinkit.css";
@import "../assets/template/css/bracket";
@import "../assets/styles/app";
</style> |
I tried removing everything except the div and export statement, and the error still comes up. |
I'm failing to recreate this. Could the error actually be from your messages file(s)? Sorry the error handling is still very basic. When does the error occur? Right after running |
After selecting that file. Other files work just fine. All languages are stored in the same file. Here's what my config looks like: const path = require('path');
const { JSONAdapter } = require('vue-translation-manager');
module.exports = {
srcPath: path.join(__dirname, 'src/components/'),
adapter: new JSONAdapter({ path: path.join(__dirname, 'src/i18n/messages.json')}),
languages: ['en', 'de'],
}; |
I can not recreate this, still. Is the messages file valid JSON? Did you try to validate this? Could you provide a small reproducable example so i could look into this? |
I can confirm the issue but I am not sure what's the source of the problem… |
@qzminski @MaxGfeller Turns out it shows this error if any of your templates contains an |
If a file does not have any translations, the CLI tool will terminate with an error:
The text was updated successfully, but these errors were encountered: