Comments (9)
I don't think this is really feasible, since Broccoli has a broccoli build
command that has nothing to do with the server. server.js
also seems like a strange place to have the build definition for your app.
For what it's worth, I'm not overly concerned with having a bunch of files in the top-level directories of my apps. The actual complexity matters much more than the number of files.
from broccoli.
The scenerio I'm describing would fit very nicely into the app I'm currently building. I'm not saying that the command line is obsolete.
The idea is to have broccoli compile the scripts and assets when the server boots up. This is especially awesome if you deploy your server code using git. No command line calls needed.
from broccoli.
In my opinion people should not expose Broccoli to the world via a server, because you are adding a lot of attack surface just to serve a few static files. I've added this to the README too. Whatever quick hacks you do for your own apps is up to you (and totally reasonable), but I don't want to make this officially sanctioned.
from broccoli.
ember apps are great to serve from CDN's
from broccoli.
@joliss Broccoli basically generates files and stores them in a directory. Express takes those files and serves them. I don't see any danger in that. (With rebuilding disabled in production mode)
@stefanpenner CDNs are more for high traffic websites. For small sites having everything in one place is more convenient. But that's one of the things I really like about ember. The serverside complexity goes to zero.
from broccoli.
@MajorBreakfast - Not to quibble, but it is quite usual to generate static sites (whether with CDN or plain S3).
from broccoli.
@rjackson 'Course :) But throwing a little site on heroku is still easier.
from broccoli.
We should pave the static deployment path.
from broccoli.
Express takes those files and serves them. I don't see any danger in that. (With rebuilding disabled in production mode)
Hm yes, this doesn't seem unreasonable to support at some point in the future. Maybe a year from now. For now let's keep the complexity low. [Edit 3/15/14: Ouch, did I really write this? No, running the broccoli middleware in production will never be good security practice.]
from broccoli.
Related Issues (20)
- checkInputPathsExist errors are unhelpful
- Concurrent building of sibling nodes? HOT 4
- potential issue with 3.3.0 release HOT 2
- [feature] capture FS stats for plugins
- [feature] be able to serve middleware without waiting for current build to complete
- [feature] be able to pause node
- Not actually shipping types
- several jobs and several output paths?
- [maintenance] mono-repo
- [feature] get plugin runtime dependencies
- Destructor Concept
- Watcher reporting (in)correct file names when saving in IntelliJ & co. HOT 1
- feature request: allow promise as entrypoint for Brocfile.js
- lack of side-effects examples
- Can ansi-html dependency be shifted to ansi-html-community to address advisory? HOT 2
- Stuck?
- Remove `esm` package HOT 2
- NodeWrapper is not a SourceNode caused by directory name
- Broccoli plugin not working after upgrading to vinyl-fs 4 HOT 1
- Vulnerability in broccoli due to unset-value
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from broccoli.