I am using vue.js 2 - I add some mdi-icons in my App.vue this generate a new error in my project
When I was trying to serve my Project but I got the error as it given as below
I apply also some commands on it but it not solved my error.
Can anyone help me to solve it
Make sure to have the .css extension, otherwise the import will fail.
As a reminder:
Install #fortawesome/fontawesome-free (with npm or yarn depending on what package manager your project uses).
Then in your main.js you can just import all.css as per the example below
import Vue from 'vue'
import App from './App.vue'
import '#fortawesome/fontawesome-free/css/all.css'
Vue.config.productionTip = false
new Vue({
render: h => h(App),
}).$mount('#app')
This will allow you to use the fa classes in regular HTML tags.
I also recommend taking a look at the Vue supported library for FontAwesome here if you want to have more granularity with your imports.
https://github.com/FortAwesome/vue-fontawesome
If you are using yarn then put this command
yarn add #fortawesome/fontawesome-free
or
If you are using npm then put this command
npm install #fortawesome/fontawesome-free
and add
#import '#fortawesome/fontawesome-free/css/all.css'; this in app.scss file
or add import '#fortawesome/fontawesome-free/css/all.css'; in app.js file
I simply solve the error by uninstall the googlefonts then again reinstall the google fonts by using following command.In my case I am using yarn so I use
yarn add #fortawesome/fontawesome-free
But in case of user that are using npm they should use following command
npm install --save #fortawesome/fontawesome-free
Also the following link is helpful google solve links for Npm and Yarn
: https://www.google.com/search?q=font%20awesome%20add%20by%20yaRN&oq=font%20awesome%20add%20by%20yaRN&aqs=chrome..69i57j33i10i160.11903j0j7&sourceid=chrome&ie=UTF-8
This one worked for me, I Downgraded #fortawesome/fontawesome-free version to ^5.15.4 in the package.json
Related
I did not find any relevant documentation regarding how to use the npm package of antmedia.
I install it by doing a yarn add #ant-media/webrtc_adaptor.
When i try to import it
import { WebRTCAdaptor } from '#antmedia/webrtc_adaptor';
Which results in this error
I realized that in package.json, it is the index.html that is in main
Is there a documentation about it ? I am currently not using React Native
Note: yarn add #ant-media/webrtc_adaptor#1.2.0 is definitly not working
I want to use tailwind typeahead vue plugin in nuxt. i have added the package using npm install vue-tailwindcss-typeahead .
then i created a file in plugins folder. tailwind-typeahead.js with following code
import Vue from 'vue'
import VueTailwindcssTypeahead from 'vue-tailwindcsscss-typeahead'
Vue.use(VueTailwindcssTypeahead)
and included the plugin file in nuxt.config.js
{ src: './plugins/tailwind-typeahead.js' }
But i am getting this error
This dependency was not found: friendly-errors 01:44:37
friendly-errors 01:44:37
* vue-tailwindcsscss-typeahead in ./plugins/tailwind-typeahead.js friendly-errors 01:44:37
friendly-errors 01:44:37
To install it, you can run: npm install --save vue-tailwindcsscss-typeahead
for reference here is the link of package
https://github.com/basarozcan/vue-tailwindcss-typeahead
You do have a typo in your plugin: vue-tailwindcsscss-typeahead.
You probably meant to write vue-tailwindcss-typeahead .
The rest is fine and it's the way to go if you want your code to be globally available in your Nuxt app. If you only want it local, import it in the component itself.
I am creating a stencil project which uses an npm package inside it, is there any options to add an npm package inside stencil project. Any suggestions I searching for a solution for quite a while.
This is how i use ck-editor in angular
<ck-editor name="editor" #myEditor [(ngModel)]="templateSetValue.template_content"
(change)="handleEditorData($event)">
</ck-editor>
Is it possible to use the same is stencil project
https://www.npmjs.com/package/ngx-ckeditor
Not sure if I understood the question correctly, but to add a package from npm in your Stencil.js project, you can just install it, like you would in any other node project:
npm install <some-package>
For example nprogress:
npm install nprogress #types/nprogress
and then import it in your code like
import nprogress from 'nprogress';
nprogress.start();
// ...
I'm trying to use the vuetify#2.0.0-alpha.17 rather than the 1.5.13 that it automatically starts with when I use vue add Vuetify. then I try this post Update Vuetify version method. I do
vue create my-app
cd my-app
vue add Vuetify
npm uninstall -S vuetify
npm install -S vuetify#2.0.0-alpha.17
and just get error
This dependency was not found:
* vuetify/src/stylus/app.styl in ./src/plugins/vuetify.js
To install it, you can run: npm install --save vuetify/src/stylus/app.styl
oh ok that's how install it. no that just gives an error too. Like I just want to start working with 2.0.0 so that when they release it- hopefully soon- I don't have to rebuild everything. Not sure why it's so hard like tell us in the docs how to do it not everybody is a wizard and googling the problem doesn't work
Comment out import 'vuetify/src/stylus/app.styl' in your src/plugins/vuetify.js file.
add import 'vuetify/src/styles/main.sass'
then npm install sass-loader
Vuetify v2 does not use the stylus. Remove import 'vuetify/src/stylus/app.styl' from src/plugins/vuetify.js. Or downgrade your vuetify plugin to 1.5.x (not recomended).
What is the proper way to import VueJs into my javascript file using NPM? I am getting a Vue is not defined error.
First, install the package:
$ npm install vue
And then import it in whatever file you want to use Vue:
import Vue from 'vue'