我想有一个仅使用无角javascript的Strongloop示例。目前尚无角度的完整工作示例。我只想在我的index.html中包含browser.bundle.js,然后从/向服务器端同步数据。实际上,我在尝试在程序中替换pouchdb,因为在开源社区中,couchdb似乎并不成功。
我无法正确跟踪此文档:在浏览器中运行回送
仅有几个步骤,但是非常简单。
slc loopback
。server/boot/root.js
。取消注释中的两行server/server.js
,它应类似于:
...
// -- Mount static files here--
// All static middleware should be registered at the end, as all requests
// passing the static middleware are hitting the file system
// Example:
var path = require('path'); //this line is now uncommented
app.use(loopback.static(path.resolve(__dirname, '../client'))); //this line is now uncommented
...
index.html
在client
目录(即client/index.html
)中创建您的内容。
这将使您通过基本的前端工作就可以进行基本设置。让我知道您是否还有其他问题。
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句