Deleted articles cannot be recovered. Draft of this article would be also deleted. Are you sure you want to delete this article?

はじめに 今、最も注目されているJavaScriptフレームワークの1つであるAngular(9.xx)と、同様に注目度の高いBaaS(Backend as a service)であるFirebaseを使って、チャット用WEBアプリをハンズオン形式で書いていきます。 「Angular+Firebase」のリアルタイム更新に興味がある方はご一読ください。 (追記:2017/6)本記事は元々「Angular2+Rails5でチャットアプリを作る」と題していましたが、ここ半年ほどひたすら「Angular+Firebase」を触ってきたので、「Angular+Firebaseでチャットアプリを作る」として、現時点(2017年6月)での最新の内容に書き換えています。 (追記:2018/1)現時点(2018年1月)での最新の内容に書き換えています。 (追記:2018/9)現時点(2018年9月)での最
[2014/08/26追記] 続編を書きました。 その③:実装編 前回の その①:考察編 の続きで、今回は その②:環境構築編 です。 で、結果から言うと、手元では下の図のように、Rails × AnguraJS の連携が上手くできました^^ (その① で述べているとおり、Rails は APIに徹してレスポンスは全て JSON。Rails の public ディレクトリで AngularJS が動作しています。) Rails 部分と AngularJS 部分が同一ソースツリーで管理できますし、フロントエンドは Grunt や Bower が使えますし、ぼっちでバックエンドとフロントエンドを作る場合にいいかも^^; 下図では、ローカル環境にて、Rails の 3000ポートで、AngularJSが動作しているのが分かるかと思います。 実装は手元では終わっているのですが、説明が長くなるので(
[2014/08/25追記] 続編を書きました。 その②:環境構築編 [2014/08/26追記] 続編を書きました。 その③:実装編 今回は その①:考察編 です。 ちょっとややこしいのですが、Railsアプリケーションの View で AngularJS を利用するということではなく、JavaScriptベースのフロントエンドアプリケーションとして AnuglarJS を利用し、サーバ側のデータを操作する為のバックエンドAPIを Rails で構築する、ということです。(まだややこしいかな..) シチュエーション的には、UIリッチなフロントエンドアプリケーションを構築するが、サーバにもデータを保持する必要がある、というもの。 (例えばシングルページアプリケーション構成や、1画面=1データモデルとはならないもの。) かつ、フロントエンドの開発は本格的にやるので、Grunt や Bower
丹内です。 掲題のとおり、BetaになっているRails5とAngular2を連携させるまでの手順をまとめました。 バージョン ruby 2.3.0 node 4.2.4 npm 3.5.3 Rails5アプリの準備 bundle initしてできたGemファイルにRails5を指定します。 source 'https://rubygems.org' gem 'rails', '5.0.0.beta1' bundle installしたらアプリを生成します。 $ rbenv exec bundle install $ bundle exec rails new . -d mysql --skip-bundle -T exist create README.md create Rakefile create config.ru create .gitignore conflict Gemfi
Releases, Offers & More Be the first to hear about our newest content, best promotions and upcoming events. Plus get 25% off your next purchase. Newsletter Sign Up Download Accounts Your email address is your account identifier. You can create a password, or just download from the links sent via email. My Orders (Resend order emails) How We're Different Hands-on instructions Solutions to real-worl
Authenticating your Angular / Rails App with JSON Web Tokens December 4, 2014 UPDATE: There have been some changes in the JWT Gem that make some of the below not work exactly right (it’ll still be about 90% the same). Specifically, they added expiration support. See my post on the same topic, but using React.js. The server side code in this post will work just as well with Angular. Overview I’m a
In my previous post I described upgrading to ui-grid 3.0, which is the not-yet-beta version of ng-grid. Over time this will offer significant benefits, at the moment it feels like a faster ng-grid. As part of implementing it on my core application I needed to rewrite the library routines for my end-to-end testing using protractor. These were reasonably tricky to work out, so I thought I’d post
How to Set Up Authentication with AngularJS and Ruby on Rails Jason Swett Jason Swett is author of AngularOnRails.com, AngularJS mentor at Thinkful, and principal of AngularJS/Rails consultancy Ben Franklin Labs. 1 Introduction 1.1 Who This Tutorial Is For Since Rails is old and AngularJS is new (relatively of course), I'm assuming there will be a lot more Rails developers interested in adding Ang
以前投稿したAngularJSとRailsの丁度良い関係を探るという記事のコード解説編です。前回はざっくりとしたアーキテクチャの紹介のみにとどめていたので、このエントリでサンプルコードの詳細について解説します。 バージョン情報 ruby 2.1.3 rails 4.1.7 devise 3.2.4 angularjs 1.3.2 ディレクトリ構造 app以下のディレクトリ構造は以下のような形です。 app ├── assets │ ├── images │ ├── javascripts │ │ ├── app │ │ │ └── tasks │ │ │ ├── tasks.controller.js.erb │ │ │ ├── tasks.html.erb │ │ │ ├── tasks.js.erb │ │ │
noteはAngularJSを使って、ブラウザで描写しているこの"note"というサービスはAngularJSを使って、JavaScript側(つまりブラウザ側)でノートの中身を公開しているみたいなのです。 それはブラウザでソースを見てみるとわかります。 例えばhttps://note.mu/sadaaki/n/nd921f3f7c635のノートのソースをChromeで見てみると・・・ まずhtmlタグにng-appのプロパティがついています。これはAngularJSを使うならば必要なプロパティで、ここからnoteはAngularJSを使っているんだなあと分かります。 AngularJSは簡単に言うと、サーバー側ではなくブラウザ側でHTMLを描写する仕組みです。これを利用するとどんな利点があるのか。僕の理解している範囲内だと、サーバー側はベースとなるHTML(上のソース)と各ノートのJSO
Fernando Villalobos Fernando Villalobos is a Rails Agile Development expert and certified SCRUM developer who has used this methodology for building high-performance apps for the past eight years. Fernando is also the organizer of Oaxaca, Mexico's Ruby User Group. 1 Introduction In this article we are going to explore two popular MV* JavaScript frameworks: AngularJS and Ember.js. This time we are
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く