# nuxt-global-var

> if you have some variables that are the same in all languages or you want to define variables by using json instead of .env, let's use this package!

Latest version **1.0.2** (published 2019-11-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install nuxt-global-var
pnpm add nuxt-global-var
yarn add nuxt-global-var
bun add nuxt-global-var
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2019-11-16 |
| First published | 2019-11-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 3.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | shinryak |
| Maintainers | minhchi3103 |
| Keywords | i18n, nuxt-i18n, nuxt, nuxtjs, vue, vuejs, global, language |

## Links

- npm: https://www.npmjs.com/package/nuxt-global-var
- Repository: https://github.com/minhchi3103/nuxt-global-var
- Homepage: https://github.com/minhchi3103/nuxt-global-var#readme
- Issues: https://github.com/minhchi3103/nuxt-global-var/issues
- npm.io page: https://npm.io/package/nuxt-global-var

## Alternatives

- [messageformat](https://npm.io/package/messageformat.md) — 329.7K weekly downloads
- [@mintlify/scraping](https://npm.io/package/@mintlify/scraping.md) — 294.8K weekly downloads
- [@mintlify/previewing](https://npm.io/package/@mintlify/previewing.md) — 209.5K weekly downloads
- [@mintlify/prebuild](https://npm.io/package/@mintlify/prebuild.md) — 209.5K weekly downloads
- [@mintlify/link-rot](https://npm.io/package/@mintlify/link-rot.md) — 206.3K weekly downloads

## Recent versions

- 1.0.2 (latest) — 2019-11-16
- 1.0.1 — 2019-11-09
- 1.0.0 — 2019-11-09

## README

# nuxt-global-var
A module for nuxtjs that make defining and using variables in component easier by using js object or json file.
### How to use
#### Install
`npm install nuxt-global-var`
#### Basic usage
Firstly, you need to add `nuxt-global-var` to your Nuxt config.
```javascript
// nuxt.config.js

{
  modules: [
    [
      'nuxt-global-var',
      {
        data: {HOST: 'shinryak.site'}
      }
    ]
  ]
}
```
Now, you can use `nuxt-global-var` in your component
```html
<templete>
	<h1>
		Test nuxt-global-var in component
	</h1>
	<p>
		{{ $get('HOST') }}
	</p>
</templete>
```
### Licence
[MIT License](https://github.com/minhchi3103/nuxt-global-var/blob/master/LICENSE "MIT License")

---
_Source: https://npm.io/package/nuxt-global-var · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
