Skip to content

Commit 3cbe18a

Browse files
committed
chore: init
0 parents  commit 3cbe18a

31 files changed

+9910
-0
lines changed

.editorconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
root = true
2+
3+
[*]
4+
indent_size = 2
5+
indent_style = space
6+
end_of_line = lf
7+
charset = utf-8
8+
trim_trailing_whitespace = true
9+
insert_final_newline = true
10+
11+
[*.md]
12+
trim_trailing_whitespace = false

.eslintignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
dist
2+
node_modules

.eslintrc.cjs

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
module.exports = {
2+
env: {
3+
browser: true,
4+
es6: true,
5+
node: true,
6+
},
7+
parser: '@typescript-eslint/parser',
8+
parserOptions: {
9+
sourceType: 'module',
10+
},
11+
plugins: ['@typescript-eslint'],
12+
extends: [
13+
'plugin:@typescript-eslint/recommended',
14+
'eslint:recommended',
15+
'plugin:prettier/recommended',
16+
'prettier',
17+
],
18+
rules: {
19+
'@typescript-eslint/ban-ts-comment': 'off',
20+
'@typescript-eslint/ban-types': 'off',
21+
'@typescript-eslint/explicit-function-return-type': 'off',
22+
'@typescript-eslint/explicit-module-boundary-types': 'off',
23+
'@typescript-eslint/no-inferrable-types': 1,
24+
'@typescript-eslint/no-explicit-any': 'off',
25+
'no-unused-vars': 'off',
26+
'no-redeclare': 'off',
27+
'no-undef': 'off',
28+
},
29+
}
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: "\U0001F41B Bug report"
2+
description: Something's not working
3+
title: "fix: "
4+
labels: ["bug"]
5+
assignees: danielroe
6+
body:
7+
- type: textarea
8+
validations:
9+
required: true
10+
attributes:
11+
label: 🐛 The bug
12+
description: What isn't working? Describe what the bug is.
13+
- type: input
14+
validations:
15+
required: true
16+
attributes:
17+
label: 🛠️ To reproduce
18+
description: A reproduction of the bug via https://stackblitz.com/github/danielroe/nuxt-ionic/tree/main/playground
19+
placeholder: https://stackblitz.com/[...]
20+
- type: textarea
21+
validations:
22+
required: true
23+
attributes:
24+
label: 🌈 Expected behaviour
25+
description: What did you expect to happen? Is there a section in the docs about this?
26+
- type: textarea
27+
attributes:
28+
label: ℹ️ Additional context
29+
description: Add any other context about the problem here.
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: "\U0001F4DA Documentation"
2+
description: How do I ... ?
3+
title: "docs: "
4+
labels: ["documentation"]
5+
assignees: danielroe
6+
body:
7+
- type: textarea
8+
validations:
9+
required: true
10+
attributes:
11+
label: 📚 Is your documentation request related to a problem?
12+
description: A clear and concise description of what the problem is.
13+
placeholder: I feel I should be able to [...] but I can't see how to do it from the docs.
14+
- type: textarea
15+
attributes:
16+
label: 🔍 Where should you find it?
17+
description: What page of the docs do you expect this information to be found on?
18+
- type: textarea
19+
attributes:
20+
label: ℹ️ Additional context
21+
description: Add any other context or information.
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: "\U0001F195 Feature suggestion"
2+
description: Suggest an idea
3+
title: "feat: "
4+
labels: ["enhancement"]
5+
assignees: danielroe
6+
body:
7+
- type: textarea
8+
validations:
9+
required: true
10+
attributes:
11+
label: 🆒 Your use case
12+
description: Add a description of your use case, and how this feature would help you.
13+
placeholder: When I do [...] I would expect to be able to do [...]
14+
- type: textarea
15+
validations:
16+
required: true
17+
attributes:
18+
label: 🆕 The solution you'd like
19+
description: Describe what you want to happen.
20+
- type: textarea
21+
attributes:
22+
label: 🔍 Alternatives you've considered
23+
description: Have you considered any alternative solutions or features?
24+
- type: textarea
25+
attributes:
26+
label: ℹ️ Additional info
27+
description: Is there any other context you think would be helpful to know?
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: "\U0001F198 Help"
2+
description: I need help with ...
3+
title: "help: "
4+
labels: ["help"]
5+
assignees: danielroe
6+
body:
7+
- type: textarea
8+
validations:
9+
required: true
10+
attributes:
11+
label: 📚 What are you trying to do?
12+
description: A clear and concise description of your objective.
13+
placeholder: I'm not sure how to [...].
14+
- type: textarea
15+
attributes:
16+
label: 🔍 What have you tried?
17+
description: Have you looked through the docs? Tried different approaches? The more detail the better.
18+
- type: textarea
19+
attributes:
20+
label: ℹ️ Additional context
21+
description: Add any other context or information.

.github/workflows/ci.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: ci
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
push:
8+
branches:
9+
- main
10+
11+
jobs:
12+
lint:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v3
17+
- run: corepack enable
18+
- uses: actions/setup-node@v3
19+
with:
20+
node-version: 16
21+
cache: "pnpm"
22+
23+
- name: 📦 Install dependencies
24+
run: pnpm install --frozen-lockfile
25+
26+
- name: 🔠 Lint project
27+
run: pnpm run lint
28+
29+
test:
30+
runs-on: ubuntu-latest
31+
32+
steps:
33+
- uses: actions/checkout@v3
34+
- run: corepack enable
35+
- uses: actions/setup-node@v3
36+
with:
37+
node-version: 16
38+
cache: "pnpm"
39+
40+
- name: 📦 Install dependencies
41+
run: pnpm install --frozen-lockfile
42+
43+
- name: 🛠 Build project
44+
run: pnpm build
45+
46+
# - name: 🧪 Test project
47+
# run: pnpm test --coverage
48+
49+
# - name: 🟩 Coverage
50+
# uses: codecov/codecov-action@v3

.gitignore

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# Dependencies
2+
node_modules
3+
4+
# Logs
5+
*.log*
6+
7+
# Temp directories
8+
.temp
9+
.tmp
10+
.cache
11+
12+
# Yarn
13+
**/.yarn/cache
14+
**/.yarn/*state*
15+
16+
# Generated dirs
17+
dist
18+
19+
# Nuxt
20+
.nuxt
21+
.output
22+
.vercel_build_output
23+
.build-*
24+
.env
25+
.netlify
26+
27+
# Env
28+
.env
29+
30+
# Testing
31+
reports
32+
coverage
33+
*.lcov
34+
.nyc_output
35+
36+
# VSCode
37+
.vscode
38+
39+
# Intellij idea
40+
*.iml
41+
.idea
42+
43+
# OSX
44+
.DS_Store
45+
.AppleDouble
46+
.LSOverride
47+
.AppleDB
48+
.AppleDesktop
49+
Network Trash Folder
50+
Temporary Items
51+
.apdisk

.npmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
shamefully-hoist=true

CODE_OF_CONDUCT.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to make participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
6+
7+
## Our standards
8+
9+
Examples of behavior that contributes to creating a positive environment include:
10+
11+
- Using welcoming and inclusive language
12+
- Being respectful of differing viewpoints and experiences
13+
- Gracefully accepting constructive criticism
14+
- Focusing on what is best for the community
15+
- Showing empathy towards other community members
16+
17+
Examples of unacceptable behavior by participants include:
18+
19+
- The use of sexualized language or imagery and unwelcome sexual attention or advances
20+
- Trolling, insulting/derogatory comments, and personal or political attacks
21+
- Public or private harassment
22+
- Publishing others' private information, such as a physical or electronic address, without explicit permission
23+
- Other conduct which could reasonably be considered inappropriate in a professional setting
24+
25+
## Our responsibilities
26+
27+
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
28+
29+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
30+
31+
## Scope
32+
33+
This Code of Conduct applies within all project spaces, and it also applies when an individual is representing the project or its community in public spaces. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
34+
35+
## Enforcement
36+
37+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [[email protected]](mailto:[email protected]). All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
38+
39+
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
40+
41+
## Attribution
42+
43+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
44+
45+
[homepage]: https://www.contributor-covenant.org
46+
47+
For answers to common questions about this code of conduct, see https://www.contributor-covenant.org/faq

LICENCE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2022 Daniel Roe
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# nuxt-ionic
2+
3+
[![npm version][npm-version-src]][npm-version-href]
4+
[![npm downloads][npm-downloads-src]][npm-downloads-href]
5+
[![Github Actions][github-actions-src]][github-actions-href]
6+
[![Codecov][codecov-src]][codecov-href]
7+
8+
> [Ionic](https://ionicframework.com/docs/) integration for [Nuxt](https://nuxtjs.org)
9+
10+
**⚠️ `nuxt-ionic` is currently a work in progress. Expect breaking changes.**
11+
12+
## Features
13+
14+
- [x] Zero-config required
15+
- [x] Auto-import Ionic components and composables throughout your app
16+
- [x] Ionic Router integration
17+
- [ ] Capacitor implementation confirmed working
18+
- [ ] Pre-rendering auto-configuration
19+
20+
## Quick setup
21+
22+
1. Add `nuxt-ionic` dependency to your project
23+
24+
```bash
25+
yarn add --dev nuxt-ionic # or npm install -D nuxt-ionic or pnpm i -D nuxt-ionic
26+
```
27+
28+
1. Add `nuxt-ionic` to the `modules` section of `nuxt.config.ts`
29+
30+
```js
31+
import { defineNuxtConfig } from 'nuxt'
32+
33+
export default defineNuxtConfig({
34+
modules: ['nuxt-ionic'],
35+
ionic: {
36+
// default options - no configuration is required
37+
integrations: {
38+
router,
39+
},
40+
css: {
41+
core: true,
42+
basic: true,
43+
utilities: false,
44+
},
45+
},
46+
})
47+
```
48+
49+
## 💻 Development
50+
51+
- Clone this repository
52+
- Enable [Corepack](https://github.com/nodejs/corepack) using `corepack enable` (use `npm i -g corepack` for Node.js < 16.10)
53+
- Run `pnpm dev:prepare` to generate type stubs.
54+
- Install dependencies using `pnpm install`
55+
- Run `pnpm dev` to start [playground](./playground) in development mode
56+
57+
## License
58+
59+
Made with ❤️
60+
61+
Published under the [MIT License](./LICENCE).
62+
63+
<!-- Badges -->
64+
65+
[npm-version-src]: https://img.shields.io/npm/v/nuxt-ionic?style=flat-square
66+
[npm-version-href]: https://npmjs.com/package/nuxt-ionic
67+
[npm-downloads-src]: https://img.shields.io/npm/dm/nuxt-ionic?style=flat-square
68+
[npm-downloads-href]: https://npmjs.com/package/nuxt-ionic
69+
[github-actions-src]: https://img.shields.io/github/workflow/status/unjs/nuxt-ionic/ci/main?style=flat-square
70+
[github-actions-href]: https://github.com/unjs/nuxt-ionic/actions?query=workflow%3Aci
71+
[codecov-src]: https://img.shields.io/codecov/c/gh/unjs/nuxt-ionic/main?style=flat-square
72+
[codecov-href]: https://codecov.io/gh/unjs/nuxt-ionic

0 commit comments

Comments
 (0)