hechuanhua / blog Goto Github PK
View Code? Open in Web Editor NEW一个基于react+redux+react-router+node+express+mongoDB的博客系统,支持服务端渲染
一个基于react+redux+react-router+node+express+mongoDB的博客系统,支持服务端渲染
开发环境下前端我本地安装node.js通过npm run dev启动,但是怎么启动后端的npm run api呢(本人新手)?
我是node初学,问一下这是什么原因,怎么解决呢?
false 'production'
/blog/src/server.js:11
import React, { Component } from 'react'
^^^^^^
SyntaxError: Unexpected token import
at Object.exports.runInThisContext (vm.js:78:16)
at Module._compile (module.js:543:28)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/blog/app.js:41:18)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.runMain (module.js:605:10)
at run (bootstrap_node.js:420:7)
这里export 好像应该是 set
现在的代码应该不能跑在ie8下吧
请问你的项目放在什么主机上啊?国内有nodejs主机吗?
你好,我想问一下你,你的index.html里面没有引入webpack打包后的bundle.js,那你是如何启动项目的
为什么我都启动了 然后在 npm run dev npm run api 这就总是报错呢,能指点一下吗
let data={username:"jack",password:"123}
fetch("user",{
method:"POST",
headers:{
"Content-Type": "application/x-www-form-urlencoded",
},
body:"username="+data.username+"&password="+data.password
}).then(
response => response.json()
).then(
data => console.log(data)
).catch(
e => console.error(e)
);
src/index.js和src/js/containers/nav.js中都有引入的组件找不到的错误,目测是大小写搞错了
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.