1. Adding a CSS Framework
Adding Bootstrap to the Project
cd {project folder}
npm install bootstrap@4.0.0
**2. Adding Bootstrap in the main.js **
find in the src Folder
import "bootstrap/dist/css/bootstrap.min.css";
3. computed property
The computed property is used to define properties that operate on the application’s data, and this allows Vue.js to detect changes to the application data efficiently, which is important in complex applications.
export default {
name: 'app',
data() {
...
},
computed: {
filteredTasks() {
return this.hideCompleted ?
this.tasks.filter(t => !t.done) : this.tasks
}
}
}