Giter Site home page Giter Site logo

todo-app's Introduction

todo-app

This app is a todo app under the SPA paradigm.
It is implemented with Vuejs, Vuex and a backend with persistence on reload with firebase.
It has a public database in firebase for 30 days.
The app has a router configuration for filtering with 3 main routes:

  • allTodos (default route: "/")

  • activeTodos (route: "/active")

  • completedTodos (route: "/completed")

The application shows a 404 page error with routes that not match with the three commented routes.

A store is implemented inside the app to manage the todos state in a module with state, getters, mutations and actions included.
The app makes use of vuex via mapActions and mapGetters to access to the state in the store.
A CRUD services for create, update or delete and HTTP client by axios are included too for the development.\

It has a main page named TodoPage.
In this main page we can find the title of the app and the main components: InputTodo, TodoList and FooterComponent.
The css styles provided are splitted in components for better performance.
The name of the task and te status (complete or not complete) are saved in firebase database for persistence.\

The components included are these ones:

  • Footer component: with filters and some information about the tasks and a button for clear completed todos.

  • Input component for creating tasks: main component to provide the name of the new task.

  • Todo list: with inputs to set the status of the todo and an editing mode with an input to edit the task.

  • Todo item: for each element in the list, it's an inner component of the todo list component.

Unit tests are included with jest.
Mocks needed for tests are included in tests directory.
The following elements have unit tests:

File (name) Directory/ type
todosApi api
FooterComponent components
InputTodo components
TodoItem components
TodoList components
TodoPage pages
todo-store store
index router
App :root

This tests could be thrown separately using these names of file (e.g., we can throw a test typing yarn test:unit TodoList command).
The tests of store have unit tests of getters, mutations and state.


Dependencies included in this project by version

The following dependencies have been used for the development of this application

Dependence Version
Axios 0.27.2
Vue 3.2.13
Vue-router 4.0.3
Vuex 4.0.0
Prettier (lintern) 2.4.1
Jest 27.0.5
@vue/test-utils 2.0.0

Project setup

This project uses yarn as a package manager, so you can use yarn commands for setup or running project options:

yarn install

Compiles and hot-reloads for development

yarn serve

Compiles and minifies for production

yarn build

Run your unit tests

yarn test:unit

Lints and fixes files

yarn lint

Customize configuration

See Configuration Reference.

todo-app's People

Watchers

lupilla avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.