hiravgandhi / angularjs-rails Goto Github PK
View Code? Open in Web Editor NEWA simple Angular.js wrapper for Rails
License: Other
A simple Angular.js wrapper for Rails
License: Other
The title says it all!
Hello,
When I installed this gem with
gem 'angularjs-rails'
bundle install
Some js files were left out. I noticed though that they exist in the github repo so I think ruby gems needs to be updated to match your current gem state. To get around this for now, I am doing:
gem 'angularjs-rails', github: 'hiravgandhi/angularjs-rails', branch: 'master'
Let me know though if I have it all WRONG =D
Thanks for the gem.
Adam
Gemfile pessimistic versions rely on correct MAJOR.MINOR.PATCH semver usage.
For instance,
gem 'angularjs-rails', '~> 1.2.12'
won't install 1.2.12.1 as it doesn't match.
gem 'angularjs-rails', '~> 1.2.12.x'
will install 1.2.12.1 (or 1.2.12.2, etc), but *won't * install 1.2.13 when it's released.
So. . . 1.2.12.1 probably should've been released as 1.2.13 as it is technically a PATCH, fixing the Rails 4 problems (and probably other issues, but the rails 4 breakage was the one that bit me).
FYI. I wouldn't yank 1.2.12.1 as yanking gems can cause annoying issues, but it might be nice to re-release 1.2.13 quickly so we can use pessimistic versioning again.
Thanks!
RubyGems.org doesn't report a license for your gem. This is because it is not specified in the gemspec of your last release.
via e.g.
spec.license = 'MIT'
# or
spec.licenses = ['MIT', 'GPL-2']
Including a license in your gemspec is an easy way for rubygems.org and other tools to check how your gem is licensed. As you can imagine, scanning your repository for a LICENSE file or parsing the README, and then attempting to identify the license or licenses is much more difficult and more error prone. So, even for projects that already specify a license, including a license in your gemspec is a good practice. See, for example, how rubygems.org uses the gemspec to display the rails gem license.
There is even a License Finder gem to help companies/individuals ensure all gems they use meet their licensing needs. This tool depends on license information being available in the gemspec. This is an important enough issue that even Bundler now generates gems with a default 'MIT' license.
I hope you'll consider specifying a license in your gemspec. If not, please just close the issue with a nice message. In either case, I'll follow up. Thanks for your time!
Appendix:
If you need help choosing a license (sorry, I haven't checked your readme or looked for a license file), GitHub has created a license picker tool. Code without a license specified defaults to 'All rights reserved'-- denying others all rights to use of the code.
Here's a list of the license names I've found and their frequencies
p.s. In case you're wondering how I found you and why I made this issue, it's because I'm collecting stats on gems (I was originally looking for download data) and decided to collect license metadata,too, and make issues for gemspecs not specifying a license as a public service :). See the previous link or my blog post about this project for more information.
I get the following error when trying to fire up my rails server:
/Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/angularjs-rails-1.2.12/lib/angularjs-rails/sprockets.rb:3:in `': undefined method`append_path' for Sprockets:Module (NoMethodError)
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/angularjs-rails-1.2.12/lib/angularjs-rails.rb:8:in `require'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/angularjs-rails-1.2.12/lib/angularjs-rails.rb:8:in`module:Rails'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/angularjs-rails-1.2.12/lib/angularjs-rails.rb:4:in `'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/angularjs-rails-1.2.12/lib/angularjs-rails.rb:3:in`'
from /Users/dkewal/moneyadvice/mortgage_calculator/lib/mortgage_calculator/engine.rb:4:in `require'
from /Users/dkewal/moneyadvice/mortgage_calculator/lib/mortgage_calculator/engine.rb:4:in`'
from /Users/dkewal/moneyadvice/mortgage_calculator/lib/mortgage_calculator.rb:1:in `require'
from /Users/dkewal/moneyadvice/mortgage_calculator/lib/mortgage_calculator.rb:1:in`'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@global/gems/bundler-1.5.2/lib/bundler/runtime.rb:76:in `require'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@global/gems/bundler-1.5.2/lib/bundler/runtime.rb:76:in`block (2 levels) in require'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@global/gems/bundler-1.5.2/lib/bundler/runtime.rb:72:in `each'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@global/gems/bundler-1.5.2/lib/bundler/runtime.rb:72:in`block in require'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@global/gems/bundler-1.5.2/lib/bundler/runtime.rb:61:in `each'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@global/gems/bundler-1.5.2/lib/bundler/runtime.rb:61:in`require'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@global/gems/bundler-1.5.2/lib/bundler.rb:131:in `require'
from /Users/dkewal/moneyadvice/mortgage_calculator/spec/dummy/config/application.rb:5:in`'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/railties-3.2.14/lib/rails/commands.rb:53:in `require'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/railties-3.2.14/lib/rails/commands.rb:53:in`block in '
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/railties-3.2.14/lib/rails/commands.rb:50:in `tap'
from /Users/dkewal/.rvm/gems/ruby-1.9.3-p484@mortgage_calculator/gems/railties-3.2.14/lib/rails/commands.rb:50:in`'
from script/rails:6:in `require'
from script/rails:6:in`'
I guess there's no need for a comment.
It would be cool to have an option you can pass, like :google
to have it automatically fetch from Google Ajax Libraries, similar to how this gem does it for jquery:
Similar to how the jquery gem includes jquery-ui and adding it to your project could be done as so:
// require angular-ui
What do you guys think?
after the update to 1.2.12
$ rake assets:precompile
rake aborted!
couldn't find file 'angular'
I guess there's no need for a comment.
Just to let you know. I didn't have time to investigate but I think it's linked to angular-resource.
It loads but not my data.
Brand new Rails 4.0.2 app. AngularJS works fine in development, but when pushed to production (Heroku) I get this error in the console when a page loads:
Error: [$injector:unpr] Unknown provider: tProvider <- t
Gemfile: https://gist.github.com/jasonfb/8274859
application.js file looks like this https://gist.github.com/jasonfb/8274880
the only angular class in my application looks like this: https://gist.github.com/jasonfb/8274925
is there something non-minisafe about the way I wrote the angular js controller?
Hi, I was using version 1.2.26 of this gem without any problems and now updated it to 1.3.36. Now my app seems to be broken but I can't figure out why as there is no error message in the console. When I look into the source code, the Angular version being included is the correct one.
ng-repeat
does still work but using ng-click
to invoke a controller method (using the controller as
syntax) doesn't. Still, no error message. Changing a variable of a object by e.g. inverting a property of it via ng-click
without using a controller works.
I followed an Angular migration guide but there was nothing really to change for me as the app is still quite small. Do you have any idea what this could be? Thanks a lot!
I believe it's relative with commit
mv@cvprcsip01:/home/mv/releases/20140212011537$ rake assets:precompile
rake aborted!
couldn't find file 'angular'
(in /home/mv/releases/20140212011537/app/assets/javascripts/application.js:16)
/usr/local/rvm/gems/ruby-2.0.0-p353/gems/sprockets-2.10.1/lib/sprockets/context. rb:106:in `resolve'
/usr/local/rvm/gems/ruby-2.0.0-p353/gems/sprockets-2.10.1/lib/sprockets/context. rb:146:in `require_asset'
https://github.com/angular/angular.js/tree/v1.2.0
Time to update :)
Please update the package to 1.3.3
unstable/angular-bootstrap
doesn't exist, docs say:
//= require unstable/angular-bootstrap
I seem to to be getting an issue installing as described here: http://stackoverflow.com/questions/11290075/rails-cant-include-angularjs
In the readme you suggest we can added angular-bootsrap but that's not included in the vendor files
Anyway https://github.com/danialfarid/angular-file-upload could be added in?
Thanks
Thank you!
Angular has some i18n files available:
https://code.angularjs.org/1.2.16/docs/guide/i18n
Would be nice to have them in this gem, so that we can use:
//= require angular
//= require i18n/angular-locale_es.js
1.3.5 fixes a pretty serious bug... thanks!
$ bundle update angularjs-rails
Updating git://github.com/hiravgandhi/angularjs-rails.git
Cloning into '/Users/allenwyma/.rvm/gems/ruby-2.0.0-p247/bundler/gems/angularjs-rails-57e57e9b9432'...
done.
There was a LoadError while loading angularjs-rails.gemspec:
cannot load such file -- versionomy from
/Users/allenwyma/.rvm/gems/ruby-2.0.0-p247/bundler/gems/angularjs-rails-57e57e9b9432/angularjs-rails.gemspec:2:in
`<main>'
Does it try to require a relative path? That's been removed in Ruby 1.9.
//= require unstable/angular-animate
gives missing file error for me.
Would it be possible to build gems for angular's unstable versions in addition to the stable ones?
I guess there's no need for a comment.
<3
The AngularJS team inadvertently published 1.3.6 as 1.3.36. Consequently, 1.3.36 of angularjs-rails was also published.
Related issue: #74
1.3.36/ 09-Dec-2014 00:11 -
...
1.3.6/ 09-Dec-2014 00:26 -
I use a manifest other that application.js
. I use a js manifest in my engine in a path like app/assets/javascript/myengine/dashboard/application.js
and when i do
//= require angular
And run my application I get an error:
couldn't find file 'angular'
Can we update the unstable branch?
http://blog.angularjs.org/2013/08/angularjs-120-rc1-spooky-giraffe.html
1.2.27 is not available on rubygems.
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.