todomvc example: pre-initialize state before mounting app

This commit is contained in:
Evan You 2016-07-14 14:45:11 -04:00
parent c1d8ccbe21
commit b8c3b5ae74
2 changed files with 4 additions and 5 deletions

View File

@ -16,7 +16,7 @@
height: 60px;
}
.todo-move, .todo-enter-active, .todo-leave-active {
transition: all .25s cubic-bezier(.55,0,.1,1);
transition: all .25s cubic-bezier(.5,0,.1,1);
}
.todo-enter, .todo-leave-active {
opacity: 0;
@ -94,6 +94,9 @@
<script>metrics.beforeRender = now()</script>
<script src="js/app.js"></script>
<script src="js/routes.js"></script>
<script>
app.$mount('.todoapp')
</script>
<script>metrics.afterRender = now()</script>
<script src="perf.js"></script>
</body>

View File

@ -21,10 +21,6 @@
};
exports.app = new Vue({
// the root element that will be compiled
el: '.todoapp',
// app initial state
data: {
todos: todoStorage.fetch(),