Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML Prototyping with Foundation for Apps Getting to Know Foundation for Apps Creating Templates

Dmytro Redko
Dmytro Redko
230 Points

Foundation for Apps is client or server technology?

Hello everyone, would someone please clarify is Foundation for Apps a client or server technology? Why do I need node.js for it to run?

Thanks.

2 Answers

Steven Parker
Steven Parker
229,785 Points

:point_right: Foundation runs entirely in the browser, so that's a client technology.

What would make you think it requires node.js? I haven't taken the course for it myself, is it possible that node.js is just used in the course to create a back-end enviroment to support the examples?

Dmytro Redko
Dmytro Redko
230 Points

Hi, That is the reason of my question - I wanted to know if node.js was only used to facilitate development environment or it is an obligatory part of Foundation for Apps framework.

Steven Parker
Steven Parker
229,785 Points

No, you can use any flavor of server with your front-end framework. The server side doesn't need to be built on node.js.

I'm still guessing the course uses node.js just because it was convenient for demonstration, and supported commonly-used helpers.

Node is used to run gulp to build out all the final files, including the concatenated and minified/uglified JavaScript, and the compiled SCSS. Once the final files are in your build folder, they are just HTML, CSS and JS, so as Steven Parker has said, this all runs in the browser, and is therefore client-side.

You could, of course, add some server-side code to do something that the client would interact with, like adding a database to persist data, or even run a separate API server that the client would request data from.