Giter VIP home page Giter VIP logo

ember-app-kit's People

Contributors

abuiles avatar bmac avatar c0urg3tt3 avatar claudeprecourt avatar dhilipsiva avatar ebryn avatar fsmanuel avatar ghedamat avatar ghempton avatar ianpetzer avatar jas avatar joefiorini avatar joliss avatar jrhe avatar kagemusha avatar lukemelia avatar machty avatar majorbreakfast avatar manoharank avatar mikegrassotti avatar mixonic avatar mysterlune avatar pangratz avatar rwjblue avatar sandalsoft avatar stefanpenner avatar tchak avatar thomasboyt avatar thomaslang avatar twokul avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ember-app-kit's Issues

Karma by default?

Should we stick with using Karma for testing, or make it optional? Karma's not too complicated and has some nice benefits, but is also a somewhat large dependency. On the other hand, making it optional introduces another layer of complexity to the Gruntfile, as we'd have to add a grunt-contrib-qunit task for CI, as well as set the npm test script to not use Karma by default.

Single file output

Is it possible to export a project down to a single HTML file, with magnification, and all JS and CSS resources inline? Are there some flags or preprocessor tasks I could configure to do this?

Use case:

Contemplating trying to develop a HTML + JS app that needs to be sent to C pre-parser and compile to C code that goes into an embedded system.

Would like to make the source file as streamline and small as possible (under 2 MB for total project).

Embedded system developer environment is a bit of a hassle to work with and so would like to not have to deal with a large number of output files before moving them over to the project to be converted to C code.

Nested controller naming convention in `needs`

How to refer posts.post controller in the following cases.

  • needs: ['posts.post']
  • {{controllers.posts.post.}}
  • this.get('controllers.posts.post')

Right now it looks something like controllers/posts instead of controllers/posts/post

Importing other libraries

Ember-App-Kit does a great job of allowing you to write modular Ember code..

I'm just struggling to understand how to import other libraries. For example, I would like use SockJS or SocketIO for websocket communications and twitter bootstrap.

I can include them as bower dependencies, importing the scripts directly in index.html and access them through the global namespace, but jshint complains that it can find the classes that I'm referring to in my routes and controllers.

Previously I've always relied on the Rails asset pipeline to organise my imports into the global namespace.. so just not quite sure how to do this. If anyone could steer me in the right direction it would be very much appreciated.

Adding an export for easy sharing with JSBin, gist, etc

How much effort would it take to have ember-app-kit export in a format that is easy to share or drop into a JSBin example?

Or even better work on integration with the folks building
http://www.embersandbox.com/

Use case is is that it would be handy to take transpiled source code and quickly dump to a paste bin type tool.

If there were hook to auto deploy or post from command line that would be great too.

Can't override nested routes

Hi,

Awesome work on Ember-App-Kit.. Really exciting project. I'm just struggling to override the nested routes automatically generated by Ember. My routes.js looks like:

function Routes() {

  this.route('bob');
    this.resource('projects', function() {
      this.route('index');
   });
} 
export default Routes;

I'm able to override the ApplicaitonRoute, BobRoute and ProjectsRoute, however I'm unable to override the ProjectsIndex route.

I've tried files named projectsIndex.js and index.js. I've placed them in the routes folder and in the routes/projects folder. I've tried a few other permuations of this.

Could anyone give me a pointer on how to name the .js file and where to put it in the directory structure. I'm assuming the actual route will be defined as:

var ProjectsIndexRoute = Ember.Route.extend({
init: function() {
  console.log('hello pr index');
}
});
export default ProjectsIndexRoute;

Documentation

I'm working on documentation here. At some point it might get merged into the readme, but I wanted to keep it separate for now so that there's not a ton of tiny commits to the repo while it's being worked on.

Stuff to add:

  • Testing
  • Building/compiling/distribution
  • Using LESS/SASS/CoffeeScript/Karma/Travis/other extras

convention for helpers

obviously app/helpers/**/*.js

but we need to make ember's helper lookup container aware, and then EAK should just work.

Problems using Ember-data models

I'm getting an error message from Ember:

Assertion failed: Your model must not be anonymous. It was (subclass of DS.Model) 

My model looks as follows:

var Project = DS.Model.extend({
  name: DS.attr('string') 
});
export default Project;

I also find that in my controllers / routes, I cannot simply import 'models/project' but need to use the fully qualified name 'appkit/models/project'

Experiencing extreme Finder hang when rebuild happens

Whenever grunt server rebuilds after detecting a file change, Finder suffers from extreme hangs (beach ball of death) where it becomes unusable for 10+ seconds.

My best initial guess is it's being caused by the files being locked and Finder of course trying to access these files meta data to update the window.

Software: OS X 10.8.4 (12E55)
Model Name: MacBook Air
Model Identifier: MacBookAir4,1
Processor Name: Intel Core i5
Processor Speed: 1.6 GHz
Number of Processors: 1
Total Number of Cores: 2
L2 Cache (per Core): 256 KB
L3 Cache: 3 MB
Memory: 4 GB

Installed:
Node v0.10.12 (via NVM)
Total Finder
Dropbox
Google Drive
CS5
VMWare
Parallels
VirtualBox
XCode
etc
Time Machine is DISABLED, no other backup software, no antivirus (duh)

Maybe it would be better to copy the files temporarily instead of locking them, if you can't keep them in memory otherwise?

Source maps

Two parts to this:

  1. Line-to-line source maps in ES6 transpiler.
  2. File-to-chunk source maps in the concatenated output.
  • file maps
  • 1:1 mappings

Deploying as per Getting Started guide is wrong or broken

Followed the instructions laid out here: https://github.com/stefanpenner/ember-app-kit/wiki/Getting-Started but even with a fresh checkout (and npm install), if you do grunt build:dist then grunt server:dist, as the guide suggests, when you pull up localhost a bunch of the files are 404 presumably because vendor is in the project root but the server is mounted in tmp/public. Briefly looking to the grunt setup, it looks like build:debug has copy:vendor but build:dist does not?

GET http://localhost:8000/vendor/jquery/jquery.js 404 (Not Found) localhost/:12
GET http://localhost:8000/vendor/handlebars/handlebars.runtime.js 404 (Not Found) localhost/:12
GET http://localhost:8000/vendor/ember/index.js 404 (Not Found) localhost/:12
GET http://localhost:8000/vendor/loader.js 404 (Not Found) 

Maybe I am or the guide is missing a step?

Question: Using a View from inside another

Hi all,

I'm feeling a bit dumb as this has me completely beat. I've checked the docs (https://github.com/stefanpenner/ember-app-kit/wiki/Referencing-Views) but this doesn't seem to work for me.

Without going into too much detail im trying the following.

in controllers/index.js

import Someview from 'appkit/views/some_view'

in views/some_view.js

var SomeView = Ember.View.extend({
   init: function(){
      console.log('Hi from the sub view');
   }
});

in templates/index.hbs

{{view App.SomeView}}

The errors I receive are:

Assertion failed: Unable to find view at path 'App.SomeView' ember.js:361
Assertion failed: You must pass a view to the #view helper, not App.SomeView () ember.js:361
Uncaught TypeError: Cannot read property 'proto' of undefined 

I added a breakpoint into the compiled app.js and SomeView is certainly not in scope at all.

Compiled code looks like:

define("appkit/views/index",
  ["appkit/views/some_view"],
  function(__dependency1__) {
    "use strict";
    var SomeView = __dependency1__.SomeView;

    var IndexView = Ember.View.extend({
      ...blah

What am i doing wrong? :(

My thoughts on EAK as I consider using it for ember-tools

Just random thoughts after spending an hour with it:

  • Can't be part of a bigger rails or express app (like discourse), might not be a goal of the project and that's fine.
  • Move app.js, routes.js into config/app.js, etc. Its also a great place for store.js, i18n, etc.
  • Don't inline script tags from vendor, require them like anything else.
  • Use almond to load the modules so we can load everybody's stuff (anybody who supports amd anyway)
  • app namespaces in module loading seems lame, but maybe smart
  • Make the module resolver a dependency, put on bower
  • Precompile only the templates that changed, make them modules
  • Don't want to ship with coffeescript, then we have to support it, which is a huge pain when it comes to generators
  • Need source maps for concat build, having a giant app.js is no good
  • Need a production build
  • Get all of ember in es6, so it depends on handlebars rsvp, backburner, etc. straight from bower

How to reference Views in Handlebars helper?

I can't seem to do a very common use case for my Ember apps:

{{view App.SomeView}}

I don't see any app kit code added to resolve these, and the AMD modules aren't appended to the application namespace obviously. My best guess is that this just isn't something appkit supports yet?

Even though I didn't think they'd work, I also tried:

{{view some}}
{{view SomeView}}
{{view views/SomeView}}
{{view app/views/SomeView}}
{{view appkit/views/SomeView}}
{{view appkit.views.SomeView}}

Somehow globalize vendor includes

Currently whenever we add a new bower component, we have to go into 3 files to include it: tests/index.html, public/index.html and karma.conf.js. Has anyone found a way to make this a little easier?

Document the grunt installer steps

I am having the kinds of issues with grunt and npm that everybody complains about with ruby, rvm and gems.

So can you node guys please refrain from creating, albeit unintentionally, the illusion that the node workflow is "easier". It is just different, and can be just as frustrating if you don't know some of the tricks already. Anyway, sorry for the rant. Trust me there is a point here, with a smidge of trolling.

I am having some issues getting this running, still new to node js stuff.

I had previously installed grunt-cli globally but with sudo because that was the only way I could get it to install. But perhaps this was a mistake.

To reset and try again I did

sudo npm uninstall -g grunt
sudo npm uninstall -g grunt-cli

now

npm list
/Users/gpotter
└── (empty)
grunt-cli  
zsh: command not found: grunt-cli
grunt    
grunt-cli: The grunt command line interface. (v0.1.9)

Fatal error: Unable to find local grunt.
...

OK where is grunt?

which grunt
/usr/local/bin/grunt

go to https://github.com/gruntjs/grunt/wiki/Getting-started

read the docs, find

npm uninstall -g grunt
npm WARN uninstall not installed in /usr/local/lib/node_modules: "grunt"

Uggh!!!
Rage starts to bubble up...

Chillax this is unix we are talking about there is a way. Maybe the global flag is the issue.

npm uninstall grunt   
npm WARN uninstall not installed in /usr/local/bin/node_modules: "grunt"

Ugh ok so what is going on

cd /usr/local/bin/node_modules
no such file or directory: /usr/local/bin/node_modules

ok makes sense

cd /usr/local/lib/node_modules
ls
grunt-cli npm

Ahh we have something.

npm uninstall grunt-cli       
unbuild [email protected]
npm ERR! Error: EACCES, unlink '/usr/local/lib/node_modules/grunt-cli'
npm ERR!  { [Error: EACCES, unlink '/usr/local/lib/node_modules/grunt-cli']
npm ERR!   errno: 3,
npm ERR!   code: 'EACCES',
npm ERR!   path: '/usr/local/lib/node_modules/grunt-cli' }
....

more rage, but remembers I had used sudo before. Bad Gordon, bad Gordon, just let some untrusted installer root your box while you are at.

Not quite sure if I should just rm the /usr/local/bin/grunt maybe that will break some other strange dependency I am not thinking about at the moment. I know I have run npm install more than once.

rage is tapering off... calmer heads are prevailing, this is unix after all there is a fix.

sudo npm uninstall grunt-cli  
Password:
unbuild [email protected]

ok check again

which grunt                 
grunt not found

Success!

Peers over at Taikado project, maybe go troll @wycats, no! We must learn Node stuff because the cool ember kids say it is good.

But have doubts when I hear @stefanpenner is afraid to run npm install in a live demo at an ember talk. Fully justified of course.

Takes a break...

OK ready to start again based on the ember-app-kit user guide...

npm install -g grunt-cli

outputs

npm http GET https://registry.npmjs.org/grunt-cli
npm http 304 https://registry.npmjs.org/grunt-cli
npm ERR! Error: EACCES, mkdir '/usr/local/lib/node_modules/grunt-cli'
npm ERR!  { [Error: EACCES, mkdir '/usr/local/lib/node_modules/grunt-cli']
npm ERR!   errno: 3,
npm ERR!   code: 'EACCES',
npm ERR!   path: '/usr/local/lib/node_modules/grunt-cli',
...

Seems like a permission error. So thus encouraged to run sudo. Bad practice node people, bad practice.

rage, rage!, rage! Hope nobody is looking, keyboard not broken yet.

Decide to go troll github, and here I am.

Not sure how to proceed. Guess I need help on how setting this up with only local user permissions. Have not tried homebrew yet.

Tips? I can help amend the user guide if someone can help straighten me up on what is going on here.

Even good getting started resources with grunt, npm and node.

I am on OS X Mountain Lion.

Thanks

By the way what started these shenanigans was this error message

grunt server
>> Local Npm module "grunt-cli" not found. Is it installed?

improve build:dist

should clean the unminified output & tests from tmp/public so it can be easily deployed

Update dependency to RC6.1

I'm currently trying to get the maintainer of the component for ember to pull in components/ember#32 which will update its dependency to RC6.1. If we want this automated in the future, I assume someone on the core team would need push access to the component repo. Who would that be?

Nested routes not working

routes.js

function Routes() {  
  this.resource('persons', {path: '/persons'}, function(){
    this.route('new', {path: '/new'});
  });
}
export default Routes;

routes/persons.js

var PersonsRoute = Ember.Route.extend({});
export default PersonsRoute;

templates/persons.hbs

<h3>Persons</h3>

Error in console:

Uncaught Error: There is no route named persons ember.js:23900
RouteRecognizer.handlersFor ember.js:23900
createNamedTransition ember.js:24535
doTransition ember.js:25113
Router.handleURL ember.js:24295
Ember.Router.Ember.Object.extend.handleURL ember.js:25385
Ember.Router.Ember.Object.extend.startRouting ember.js:25362
Ember.Application.Ember.Namespace.extend.startRouting ember.js:29004
Ember.Application.Ember.Namespace.extend.didBecomeReady ember.js:28962
DeferredActionQueues.flush ember.js:4901
Backburner.end ember.js:4591
Backburner.run ember.js:4630
Ember.run ember.js:5112
Ember.Application.Ember.Namespace.extend.scheduleInitialize ember.js:28708
jQuery.Callbacks.fire jquery.js:1037
jQuery.Callbacks.self.fireWith jquery.js:1148
jQuery.extend.ready jquery.js:433
completed

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.