DEV Community

Discussion on: Create Web Components with Vue.js

Collapse
 
brianlovega profile image
Brian Loveless

Awesome article, love the explanations. thewebdev.info is now bookmarked as there is a lot for me to learn still. But as a newbie, I have a few questions with following along with this example.

When you say "create a .env file in the root folder and add VUE_APP_APIKEY as the key and the API key as the value."

Does it matter what we name it? And I know security is at the forefront of many web issues but, what can someone really do with my free API key for free weather info?
Run up the usage so that the site doesn't work? There is no credit card info or anything given for the free key so why hide it? And if it is in a file that GitHub ignores how do we have the key available to use when the site is deployed?

Also wondering what do we call the file used here... "Next, we create a mixins folder in the src folder and add: ..."

Since you can't just add code to an empty folder.

I have also followed along with all the installs and steps and at the end of the article, I do not seem to have a "store.js" file to replace any code. Do I just create it? if so where?

Is the full code / example available anywhere?
Is there a live demo version?

Sorry to be a pest but I would love to view the weather with VUE and this is one of the closest to complete articles I have found.

Collapse
 
aumayeung profile image
John Au-Yeung

Thanks so much for reading.

As long as the env variable starts with VUE_ it's fine.

Yes. Whatever you don't have you create it in the folder specified.

The OpenWeatherApi has a free version so you can use it for free.

I can send you the link for the code repo once I find it.

I am happy that you read stuff and I am happy to answer your questions.