File tree Expand file tree Collapse file tree
examples/async-data/pages Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -20,10 +20,11 @@ export default {
2020}
2121 </script >
2222
23- <style >
23+ <style scoped >
2424p {
2525 font-size : 20px ;
2626 text-align : center ;
2727 padding : 100px ;
28+ padding-bottom : 0 ;
2829}
2930 </style >
Original file line number Diff line number Diff line change 1010const axios = require (' axios' )
1111
1212export default {
13- async data ({ req }) {
14- const res = await axios .get (' https://jsonplaceholder.typicode.com/posts/1' )
15- return { post: res .data }
13+ data ({ req }) {
14+ return new Promise ((resolve , reject ) => {
15+ axios .get (' https://jsonplaceholder.typicode.com/posts/1' )
16+ .then ((res ) => {
17+ resolve ({
18+ post: res .data
19+ })
20+ })
21+ })
1622 }
1723}
1824 </script >
1925
20- <style >
26+ <style scoped >
2127p {
2228 font-size : 20px ;
2329 text-align : center ;
2430 padding : 100px ;
31+ padding-bottom : 0 ;
2532}
2633 </style >
Original file line number Diff line number Diff line change @@ -208,7 +208,6 @@ function webpackWatchAndUpdate () {
208208 const MFS = require ( 'memory-fs' ) // <- dependencies of webpack
209209 const mfs = new MFS ( )
210210 const serverConfig = getWebpackServerConfig . call ( this )
211- console . log ( serverConfig )
212211 const serverCompiler = webpack ( serverConfig )
213212 const outputPath = join ( serverConfig . output . path , serverConfig . output . filename )
214213 serverCompiler . outputFileSystem = mfs
Original file line number Diff line number Diff line change 11{
22 "name" : " nuxt" ,
3- "version" : " 0.1.2 " ,
3+ "version" : " 0.1.3 " ,
44 "description" : " A minimalistic framework for server-rendered Vue.js applications (inspired by Next.js)" ,
55 "main" : " index.js" ,
66 "license" : " MIT" ,
You can’t perform that action at this time.
0 commit comments