You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
As previously discussed in PR #107, I am having trouble making webpack work with Rails in my development environment, which is Cloud 9. The problem seems to be that Cloud 9 only allows the 0.0.0.0 interface and a few ports (8080, 8081, etc.). Basically, I am experiencing the same problem as in this issue. It seems fixed they problem by adding webpack-dev-server/client?https://0.0.0.0:8080 as an en
Steps to reproduce Using rails 5.1.0-beta1, run yarn add actioncable@5.1.0-beta to get actioncable in your application to be 5.1.0-beta1. Create a file in frontend/javascripts that will be loaded by webpacker that imports actioncable as such import * as ActionCable from 'actioncable' (this is typescript syntax) Expected behavior ActionCable should be loaded normally and no problem should occur as
Rails5.1が今betaで出ていますね。中でも目玉はwebpacker.gemによるモダンなフロントエンド開発がRailsに導入されることでしょう。 今までのRailsのasset pipelineとは別に、yarnによって依存性を管理しwebpackで結合する独立したjsのビルドシステムがサポートされます。 これによって、以下のような従来のasset pipelineでは解決がむずかしかった問題への解が示されました。 coffee scriptへの依存 npmによる依存性、バージョン管理が難しい javascriptのライブラリが野良gem化されてupdateされない問題 webpacker.gemはyarn/webpackの薄いwrapperとなっていて、加えて幾つかのrakeタスクを追加することでフロントエンド開発をサポートします。 具体的には以下のような機能が提供されます。 y
Webpacker has served the Rails community for over five years as a bridge to compiled and bundled JavaScript. This bridge is no longer needed for most people in most situations following the release of Rails 7. We now have three great default answers to JavaScript in 2021+, and thus we will no longer be evolving Webpacker in an official Rails capacity. For applications currently using Webpacker, th
はじめに フロントエンドへスプラトゥーンを決めるために、Rails プロジェクト内で JavaScript を楽に良い感じに分離する方法を考えてみました。 先人たちが様々な方法を提示してくださっていましたが、設定が大掛かりだったり、何種類かのツールを活用したりと、自分にはどうもハードルが高かったため、より簡単な方法を模索しました。 TL;DR Initial commit で、この記事でこれから行う設定をコミットしています。 necojackarc-sandbox/rails_with_webpack 特徴 Sprockets の良い所はそのまま活用 導入ツールは実質 WebPack のみ 設定項目が少なく簡単 おそらくほぼメンテナンスフリー 概要 以下のような流れで、JavaScript のコーディング、ビルド、配信を行います。 frontendディレクトリ以下で JavaScript
var path = require('path') var webpack = require('webpack') var ExtractTextPlugin = require('extract-text-webpack-plugin') var BrowserSyncPlugin = require('browser-sync-webpack-plugin') var AssetsPlugin = require('assets-webpack-plugin') require('dotenv').config() const isProduction = (process.env.NODE_ENV === 'production') var assets = new AssetsPlugin({ filename: 'webpack-asset-manifest.json', i
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く