Skip to content

Commit

Permalink
Migration to Nuxt3 (#96)
Browse files Browse the repository at this point in the history
* Innitial migration to Nuxt3

* Moving to yarn

* Pinia store with persisted state

* Ignoring output folder

* Components and Store conversion

* v-skeleton is part of labs and labs is not supported by the extension for now

* Renamed from duration to period

* Displaying the totalProfitPercentage as %

* Underlined components for styling

* Vuetify 3 upgrade changes

* v-badge upgrade

* Number steps at .01

* Formatting

* Unit Tests

* SEO

* IOF

* Bump nuxt from 3.7.1 to 3.8.1

* Bump @pinia/nuxt from 0.4.11 to 0.5.1

* Removing old configurations

* Removing old configurations
  • Loading branch information
marcelorodrigo authored Nov 13, 2023
1 parent a2da6bf commit ca09bb5
Show file tree
Hide file tree
Showing 70 changed files with 7,257 additions and 42,535 deletions.
16 changes: 0 additions & 16 deletions .babelrc

This file was deleted.

15 changes: 0 additions & 15 deletions .eslintrc.js

This file was deleted.

25 changes: 7 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,18 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout 🛎
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup node env 🏗
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
check-latest: true
cache: 'npm'
cache: 'yarn'
- name: Install dependencies 👨🏻‍💻
run: npm ci --prefer-offline --no-audit
- name: Run linter 👀
run: npm run lint
# - name: Run tests 🧪
# run: npm run test
# - name: SonarCloud Scan 👾
# uses: SonarSource/sonarcloud-github-action@master
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
# with:
# args: >
# -Dsonar.organization=rendafixa
# -Dsonar.projectKey=rendafixa_rendafixa.github.io
run: yarn install --immutable --immutable-cache --check-cache
- name: Tests 🧑‍🔬
run: yarn test
- name: Deploy 😎
run: npm run generate
run: yarn generate
25 changes: 6 additions & 19 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,30 +18,17 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout 🛎
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup node env 🏗
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18
check-latest: true
cache: 'npm'
cache: 'yarn'
- name: Install dependencies 👨🏻‍💻
run: npm ci --prefer-offline --no-audit
- name: Run linter 👀
run: npm run lint
# - name: Run tests 🧪
# run: npm run test
# - name: SonarCloud Scan 👾
# uses: SonarSource/sonarcloud-github-action@master
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
# with:
# args: >
# -Dsonar.organization=rendafixa
# -Dsonar.projectKey=rendafixa_rendafixa.github.io
run: yarn install --immutable --immutable-cache --check-cache
- name: Setup Pages
uses: actions/configure-pages@v2
with:
Expand All @@ -56,7 +43,7 @@ jobs:
restore-keys: |
${{ runner.os }}-nuxt-build-
- name: Deploy 😎
run: npm run generate
run: yarn generate
- name: Publish 🍻
uses: actions/upload-pages-artifact@v1
with:
Expand All @@ -70,4 +57,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1
uses: actions/deploy-pages@v1
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ typings/

# Nuxt generate
dist
.output

# vuepress build output
.vuepress/dist
Expand Down
97 changes: 0 additions & 97 deletions .prettierignore

This file was deleted.

5 changes: 0 additions & 5 deletions .prettierrc

This file was deleted.

31 changes: 31 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,34 @@
[![Technical Debt](https://sonarcloud.io/api/project_badges/measure?project=rendafixa_rendafixa.github.io&metric=sqale_index)](https://sonarcloud.io/summary/new_code?id=rendafixa_rendafixa.github.io)

Simule seus investimentos CDB/RDB, LCI/LCA, Poupança e Tesouro Selic.


## Setup

Make sure to install the dependencies:

```bash
yarn install
```

## Development Server

Start the development server on `http://localhost:3000`:

```bash
yarn dev
```

## Production

Build the application for production:

```bash
yarn build
```

Locally preview production build:

```bash
yarn preview
```
4 changes: 0 additions & 4 deletions assets/variables.scss

This file was deleted.

41 changes: 15 additions & 26 deletions components/InvestmentInput.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,22 @@
<script setup lang='ts'>
import AmountInput from '~/components/investment/AmountInput.vue'
import IndexDiInput from '~/components/investment/IndexDiInput.vue'
import IndexSelicInput from '~/components/investment/IndexSelicInput.vue'
import IndexCdbInput from '~/components/investment/IndexCdbInput.vue'
import IndexLcxInput from '~/components/investment/IndexLcxInput.vue'
import PeriodInput from './investment/PeriodInput.vue'
import PeriodTypeInput from './investment/PeriodTypeInput.vue'
</script>

<template>
<v-card elevation="2">
<v-card-title class="text-h6">Investimento</v-card-title>
<v-card-text>
<v-form @submit.prevent="submit">
<v-form @submit.prevent>
<AmountInput />
<div class="duration-container">
<DurationInput />
<DurationTypeInput />
<div class="period-container">
<PeriodInput />
<PeriodTypeInput />
</div>
<IndexDiInput />
<IndexSelicInput />
Expand All @@ -16,29 +26,8 @@
</v-card-text>
</v-card>
</template>
<script>
import AmountInput from './investment/AmountInput.vue'
import DurationTypeInput from './investment/DurationTypeInput.vue'
import DurationInput from './investment/DurationInput.vue'
import IndexDiInput from './investment/IndexDiInput.vue'
import IndexSelicInput from './investment/IndexSelicInput.vue'
import IndexCdbInput from './investment/IndexCdbInput.vue'
import IndexLcxInput from './investment/IndexLcxInput.vue'
export default {
components: {
AmountInput,
DurationTypeInput,
DurationInput,
IndexDiInput,
IndexSelicInput,
IndexCdbInput,
IndexLcxInput
}
}
</script>

<style scoped>
.duration-container {
.period-container {
display: flex;
flex-direction: row;
align-items: center;
Expand Down
Loading

0 comments on commit ca09bb5

Please sign in to comment.