{"id":837,"date":"2021-08-26T17:00:47","date_gmt":"2021-08-26T08:00:47","guid":{"rendered":"https:\/\/weseek.co.jp\/tech\/?p=837"},"modified":"2023-04-17T11:33:46","modified_gmt":"2023-04-17T02:33:46","slug":"railsxreactxtypescript-%e3%81%a7%e4%bd%9c%e3%82%8b-web%e3%82%a2%e3%83%97%e3%83%aa%e5%85%a5%e9%96%80","status":"publish","type":"post","link":"https:\/\/weseek.co.jp\/tech\/837\/","title":{"rendered":"Rails\u00d7React\u00d7TypeScript\u3067\u4f5c\u308bWEB\u30a2\u30d7\u30ea\u5165\u9580"},"content":{"rendered":"<p>\u3053\u306e\u8a18\u4e8b\u306f\u30012021\/8\/19 \u306b\u884c\u308f\u308c\u305f WESEEK Tech Conference \u306e\u5185\u5bb9\u3092\u307e\u3068\u3081\u305f\u3082\u306e\u3067\u3059\u3002<\/p>\n<h1>\u76ee\u6b21<\/h1>\n\n<h1>\u306f\u3058\u3081\u306b<\/h1>\n<h2>\u69cb\u6210\u306e\u6982\u8981<\/h2>\n<p>\u307e\u305a\u521d\u3081\u306b\u4eca\u56de\u7d39\u4ecb\u3059\u308b\u69cb\u6210\u306e\u6982\u8981\u3092\u8aac\u660e\u3057\u307e\u3059\u3002<\/p>\n<p><img src=\"https:\/\/weseek.co.jp\/tech\/wp-content\/uploads\/2021\/08\/20a2a95c20951eef4e7345a0246c742b.png\" alt=\"\" \/><\/p>\n<p>\u56f3\u3092\u898b\u3066\u3044\u305f\u3060\u3051\u308c\u3070\u308f\u304b\u308b\u901a\u308a MVC \u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u3067\u3042\u308b <a href=\"https:\/\/rubyonrails.org\/\">Ruby on Rails<\/a> \u306e View \u5c64\u306b <a href=\"https:\/\/github.com\/rails\/webpacker\">Wepacker<\/a> \u3092\u4f7f\u3063\u3066 React \u3084\u305d\u306e\u307b\u304b\u306e JavaScropt \u3092\u30d0\u30f3\u30c9\u30eb\u3057\u3066 erb \u306a\u3069\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u304b\u3089\u547c\u3073\u51fa\u3057\u3066\u4f7f\u3046\u3068\u3044\u3046\u69cb\u6210\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u69cb\u6210\u3092\u53d6\u308b\u3068\u57fa\u672c\u7684\u306b\u306f Rails \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3092\u4f5c\u6210\u3059\u308b\u3053\u3068\u306b\u306a\u308b\u306e\u3067\u3001\u65e2\u5b58\u306e Rails \u306e\u77e5\u8b58\u3084\u3001\u3059\u3067\u306b\u69cb\u7bc9\u3055\u308c\u3066\u3044\u308b Rails \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306b React \u3092\u90e8\u5206\u7684\u306b\u8ffd\u52a0\u3059\u308b\u306a\u3069\u3068\u3044\u3046\u4f7f\u3044\u65b9\u304c\u53ef\u80fd\u3067\u3059\u3002<\/p>\n<p><!--more--><\/p>\n<h2>\u8a18\u4e8b\u4e2d\u30b3\u30fc\u30c9\u306e\u5229\u7528\u30d0\u30fc\u30b8\u30e7\u30f3\u306b\u3064\u3044\u3066<\/h2>\n<pre><code># ruby -v\nruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [x86_64-linux]\n# rails -v\nRails 6.1.4\n# node -v\nv16.5.0<\/code><\/pre>\n<p>\u5404\u7a2e\u30d0\u30fc\u30b8\u30e7\u30f3\u306f\u767a\u8868\u6642\u70b9\u306e\u6700\u65b0\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u3092\u4f7f\u7528\u3057\u3066\u3044\u307e\u3059\u3002Ruby \u304c 3\u7cfb\u3067\u3042\u308a\u7279\u306b\u65b0\u3057\u3044\u306e\u3067\u4ed6\u306b\u4f7f\u7528\u3057\u3066\u3044\u308b gem \u304c Ruby3 \u306b\u5bfe\u5fdc\u3057\u3066\u306a\u3044\u3068\u3044\u3046\u53ef\u80fd\u6027\u3082\u3042\u308b\u306e\u3067\u6ce8\u610f\u304c\u5fc5\u8981\u3067\u3059\u3002<\/p>\n<p>\u307e\u305f\u3001(\u524d\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u306b\u6bd4\u3079\u3066)\u4f7f\u3063\u3066\u308b\u4eba\u304c\u307e\u3060\u5c11\u306a\u3044\u3068\u601d\u308f\u308c\u308b\u306e\u3067\u3069\u3053\u306b\u843d\u3068\u3057\u7a74\u304c\u3042\u308b\u304b\u308f\u304b\u3089\u306a\u3044\u306e\u3067\u6700\u65b0\u7248\u306e\u5229\u7528\u3067\u30cf\u30de\u3063\u305f\u5834\u5408\u306f\u81ea\u5df1\u8cac\u4efb\u3067\u3002\u3002\u3002<\/p>\n<p>\u4ed6\u8a73\u3057\u3044\u30e9\u30a4\u30d6\u30e9\u30ea\u306e\u30d0\u30fc\u30b8\u30e7\u30f3\u306a\u3069\u306f\u30b5\u30f3\u30d7\u30eb\u30ea\u30dd\u30b8\u30c8\u30ea\u306e Dockerfile\u3001Gemfile\u3001package.json \u3092\u3054\u78ba\u8a8d\u304f\u3060\u3055\u3044\u3002<br \/>\n\u3061\u306a\u307f\u306b\u81ea\u5206\u304c\u3053\u306e\u69cb\u6210\u3092\u672c\u756a\u74b0\u5883\u3067\u52d5\u304b\u3057\u3066\u3044\u308b\u30d0\u30fc\u30b8\u30e7\u30f3\u306f\u4ee5\u4e0b\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre><code># ruby -v\nruby 2.7.4p191 (2021-07-07 revision a21a3b7d23) [x86_64-linux-musl]\n# rails -v\nRails 6.0.4\n# node -v\nv12.22.4<\/code><\/pre>\n<h1>\u74b0\u5883\u69cb\u7bc9<\/h1>\n<h2>Rails \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u7528\u610f<\/h2>\n<p>\u57fa\u672c\u7684\u306b Webpacker \u306e\u52d5\u304f\u30d0\u30fc\u30b8\u30e7\u30f3<a href=\"https:\/\/github.com\/rails\/webpacker#prerequisites\">(Rails 5.2 \u4ee5\u4e0a)<\/a> \u3067\u3042\u308c\u3070\u65b0\u3057\u304f<code>rails new<\/code> \u3057\u3066\u3082\u65e2\u5b58\u306e Rails \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u4f7f\u3063\u3066\u3082\u554f\u984c\u306a\u3044\u3068\u601d\u308f\u308c\u307e\u3059\u3002<\/p>\n<p>\u81ea\u5206\u306e\u5834\u5408\u306f\u30ed\u30fc\u30ab\u30ebPC\u306b\u3042\u308c\u3053\u308c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u305f\u304f\u306a\u3044\u306e\u3067\u57fa\u672c\u7684\u306b\u306f\u3059\u3079\u3066 Docker \u4e0a\u3067\u3084\u3063\u3066\u304a\u308a\u3001\u4ee5\u4e0b\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u3092 clone \u3057\u3066 <a href=\"https:\/\/azure.microsoft.com\/ja-jp\/products\/visual-studio-code\/\">VSCode<\/a> \u306e <a href=\"https:\/\/code.visualstudio.com\/docs\/remote\/containers\">devcontainer<\/a> \u304b\u3089\u958b\u304f\u3068\u5229\u7528\u30d0\u30fc\u30b8\u30e7\u30f3\u3067\u7d39\u4ecb\u3057\u305f\u30d0\u30fc\u30b8\u30e7\u30f3\u306e <code>rails new<\/code> \u3057\u305f\u3070\u304b\u308a\u306e Rails \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u304c\u7528\u610f\u3067\u304d\u307e\u3059\u3002<\/p>\n<ul>\n<li><a href=\"https:\/\/github.com\/haruhikonyan\/rails-devcontainer\/tree\/rails6.1.4-and-ruby3.0.2-and-mysql\">https:\/\/github.com\/haruhikonyan\/rails-devcontainer\/tree\/rails6.1.4-and-ruby3.0.2-and-mysql<\/a>\n<pre><code>$ git clone  https:\/\/github.com\/haruhikonyan\/rails-devcontainer -b rails6.1.4-and-ruby3.0.2-and-mysql<\/code><\/pre>\n<\/li>\n<\/ul>\n<p>\u3061\u306a\u307f\u306b\u305f\u3060\u306e\u5ba3\u4f1d\u3067\u306f\u3042\u308b\u306e\u3067\u3059\u304c devcontainer \u3092\u4f7f\u3063\u3066 Rails \u306e\u958b\u767a\u3092\u3059\u308b\u89e3\u8aac\u307f\u305f\u3044\u306a\u3082\u306e\u306f\u81ea\u5206\u306e\u66f8\u3044\u305f\u4ee5\u4e0b\u8a18\u4e8b\u304c\u53c2\u8003\u306b\u306a\u308b\u304b\u3068\u601d\u3044\u307e\u3059<\/p>\n<ul>\n<li><a href=\"https:\/\/qiita.com\/haruhikonyan\/items\/b5b04c168d3f9de0e210\">VSCode \u3068 devcontainer \u3067\u4f5c\u308b Rails \u958b\u767a\u74b0\u5883<\/a>\n<ul>\n<li>\u8a18\u4e8b\u4e2d\u3067\u306f\u53e4\u3044\u30d0\u30fc\u30b8\u30e7\u30f3\u306e\u30d6\u30e9\u30f3\u30c1\u3067\u7acb\u3061\u4e0a\u3052\u3066\u308b\u306e\u3067\u6ce8\u610f<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2>React(react-rails) \u5c0e\u5165<\/h2>\n<p>\u307e\u305a\u306f Rails \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306b React \u306e\u5c0e\u5165\u3092\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f <a href=\"https:\/\/github.com\/reactjs\/react-rails\">react-rails<\/a> \u3068\u3044\u3046 gem \u3092\u5229\u7528\u3057\u3066 React \u3092\u5c0e\u5165\u3057\u307e\u3059\u3002<\/p>\n<p>\u3084\u308b\u3053\u3068\u3068\u3057\u3066\u306f <a href=\"https:\/\/github.com\/reactjs\/react-rails\">react-rails<\/a> \u306e <a href=\"https:\/\/github.com\/reactjs\/react-rails#get-started-with-webpacker\">Get started with Webpacker<\/a> \u306b\u66f8\u3044\u3066\u3042\u308b\u30b3\u30de\u30f3\u30c9\u3092\u305d\u306e\u307e\u307e\u6253\u3063\u3066\u3044\u304d\u307e\u3059\u3002\u305d\u3046\u3059\u308b\u3068 Webpacker \u304c\u3044\u3044\u611f\u3058\u306b\u8a2d\u5b9a\u3092\u751f\u6210\u3057\u3066\u304f\u308c\u3066\u305d\u308c\u3060\u3051\u3067 React \u304c\u4f7f\u3048\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u4ee5\u4e0b\u306f\u81ea\u5206\u304c\u5b9f\u969b\u306b\u6253\u3063\u305f\u30b3\u30de\u30f3\u30c9\u3067\u3059\u3002<\/p>\n<pre><code># edit Gemfile\ngem \u2018react-rails\u2019 \u2190\u8ffd\u52a0\n\n# bundle install\n# rails webpacker:install\n# rails webpacker:install:react\n# rails generate react:install\n# rails g react:component HelloWorld greeting:string<\/code><\/pre>\n<p>\u3053\u306e\u30b3\u30de\u30f3\u30c9\u3092\u6253\u3063\u305f\u6642\u306e\u5dee\u5206\u304c\u4ee5\u4e0b\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<ul>\n<li><a href=\"https:\/\/github.com\/haruhikonyan\/rails-devcontainer\/commit\/7bb2358ce47edc029ed1bf10dd11467cccb656cf\">https:\/\/github.com\/haruhikonyan\/rails-devcontainer\/commit\/7bb2358ce47edc029ed1bf10dd11467cccb656cf<\/a><\/li>\n<\/ul>\n<h3>\u5dee\u5206\u8a73\u7d30<\/h3>\n<ul>\n<li>Gemfile, Gemfile.lock\n<ul>\n<li>react-rails \u3092\u5c0e\u5165\u3057\u305f\u305f\u3081\u306e\u5dee\u5206<\/li>\n<\/ul>\n<\/li>\n<li>app\/javascript\/components\/HelloWorld.js\n<ul>\n<li><code>rails g react:component HelloWorld<\/code> \u30b3\u30de\u30f3\u30c9\u306b\u3066\u4f5c\u6210\u3055\u308c\u305f\u30b5\u30f3\u30d7\u30eb\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8<\/li>\n<\/ul>\n<\/li>\n<li>app\/javascript\/packs\/application.js, server_rendering.js, babel.config.js, config\/webpacker.ym\n<ul>\n<li>webpacker \u4e0a\u3067 React \u3092\u4f7f\u3046\u305f\u3081\u306b\u5fc5\u8981\u306a\u8a2d\u5b9a\u306a\u3069<\/li>\n<\/ul>\n<\/li>\n<li>app\/javascript\/packs\/hello_react.jsx\n<ul>\n<li>react-rails \u3092\u4f7f\u308f\u306a\u3044\u5834\u5408\u306e\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u4f8b<\/li>\n<\/ul>\n<\/li>\n<li>package.json, yarn.lock\n<ul>\n<li>React \u3092\u5229\u7528\u3059\u308b\u306e\u306b\u5fc5\u8981\u306a npm package \u304c\u8ffd\u52a0\u3055\u308c\u305f\u5dee\u5206<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2>TypeScript \u5c0e\u5165<\/h2>\n<p>\u7d9a\u3044\u3066 React(react-rails) \u306e\u5c0e\u5165\u304c\u3067\u304d\u305f\u306e\u3067 TypeScript \u3082\u4f7f\u3048\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u3053\u3061\u3089\u3082 <a href=\"https:\/\/github.com\/reactjs\/react-rails#typescript-support\">react-rails \u304c\u516c\u5f0f\u306b\u30b5\u30dd\u30fc\u30c8<\/a> \u3057\u3066\u3044\u308b\u306e\u3067\u5148\u307b\u3069\u3068\u540c\u69d8\u30b3\u30de\u30f3\u30c9\u3092\u6253\u3063\u3066\u3044\u304f\u3060\u3051\u3067\u5c0e\u5165\u304c\u5b8c\u4e86\u3057\u307e\u3059\u3002<\/p>\n<p>TypeScript \u306e\u5c0e\u5165\u304c\u3067\u304d\u305f\u306e\u3067\u3053\u306e\u30bf\u30a4\u30df\u30f3\u30b0\u3067 js \u3067\u66f8\u304b\u308c\u305f\u30b5\u30f3\u30d7\u30eb\u306e\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092 tsx \u306b\u4fee\u6b63\u3082\u3057\u3066\u3044\u304d\u307e\u3059\u3002\u4ed6\u306b\u3082 <code>rails new<\/code> \u3057\u305f\u6642\u306b\u4f5c\u6210\u3055\u308c\u305f js \u3067\u66f8\u304b\u308c\u305f\u30d5\u30a1\u30a4\u30eb\u3092 ts \u306b\u66f8\u304d\u76f4\u3057\u3066\u3082\u826f\u3044\u3067\u3057\u3087\u3046\u3002<\/p>\n<p>\u4ee5\u4e0b\u306f\u81ea\u5206\u304c\u5b9f\u969b\u306b\u6253\u3063\u305f\u30b3\u30de\u30f3\u30c9\u3067\u3059\u3002<\/p>\n<pre><code># rails webpacker:install:typescript\n# mv app\/javascript\/components\/HelloWorld.js app\/javascript\/components\/HelloWorld.tsx\n# edit app\/javascript\/components\/HelloWorld.tsx\n tsx \u304b\u3064FC\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306b\u4fee\u6b63\n# yarn remove babel-plugin-transform-react-remove-prop-types prop-types\n# rm app\/javascript\/packs\/hello_react.jsx<\/code><\/pre>\n<p>\u3053\u306e\u30b3\u30de\u30f3\u30c9\u3092\u6253\u3063\u305f\u6642\u306e\u5dee\u5206\u304c\u4ee5\u4e0b\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<ul>\n<li><a href=\"https:\/\/github.com\/haruhikonyan\/rails-devcontainer\/commit\/655dc59bdb839f0c76fa32db29925d2eb4b24659\">https:\/\/github.com\/haruhikonyan\/rails-devcontainer\/commit\/655dc59bdb839f0c76fa32db29925d2eb4b24659<\/a><\/li>\n<\/ul>\n<p>\u30b3\u30de\u30f3\u30c9\u4e0a\u5b9f\u65bd\u3057\u305f\u3053\u3068\u3092\u308f\u304b\u308a\u3084\u3059\u304f\u3059\u308b\u305f\u3081 edit \u30b3\u30de\u30f3\u30c9\u306a\u3069\u3092\u4f7f\u3063\u3066\u3044\u307e\u3059\u304c\u3001VSCode \u306a\u3069\u306e\u30a8\u30c7\u30a3\u30bf\u4e0a\u3067\u306e\u64cd\u4f5c\u3067\u554f\u984c\u306a\u3044\u3067\u3059\u3002<\/p>\n<h3>\u5dee\u5206\u8a73\u7d30<\/h3>\n<ul>\n<li>app\/javascript\/components\/HelloWorld.js \u2192 HelloWorld.tsx\n<ul>\n<li>jsx \u306e\u30af\u30e9\u30b9\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304b\u3089 tsx \u306e\u30d5\u30a1\u30f3\u30af\u30b7\u30e7\u30f3\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3078\u4fee\u6b63<\/li>\n<\/ul>\n<\/li>\n<li>babel.config.js, config\/webpacker.yml, tsconfig.json\n<ul>\n<li>TypeScript\u3092\u5229\u7528\u3059\u308b\u305f\u3081\u306e\u8a2d\u5b9a<\/li>\n<\/ul>\n<\/li>\n<li>tsconfig \u306b\u306f <code>&quot;allowSyntheticDefaultImports&quot;: true<\/code> \u3068\u3044\u3046\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u8ffd\u52a0\u3057\u3001<code>import React from &quot;react&quot;<\/code> \u3068\u3044\u3046\u66f8\u5f0f\u306e inport \u6587\u3092\u53ef\u80fd\u306b\u3059\u308b\u305f\u3081\u8ffd\u52a0\u3057\u307e\u3059\u3002\n<ul>\n<li>\u30c7\u30d5\u30a9\u30eb\u30c8\u3060\u3068 <code>import * as React from &#039;react&#039;<\/code><\/li>\n<\/ul>\n<\/li>\n<li>package.json, yarn.lock\n<ul>\n<li>Typescript \u3092\u5229\u7528\u3059\u308b\u306e\u306b\u5fc5\u8981\u306a npm package \u304c\u8ffd\u52a0\u3055\u308c\u305f\u5dee\u5206<\/li>\n<li>\u4e0d\u8981\u306a\u30e9\u30a4\u30d6\u30e9\u30ea\u306e\u524a\u9664\n<ul>\n<li>prop-types \u7cfb\u306f TypeScript \u306b\u3057\u305f\u3053\u3068\u306b\u3088\u308a\u3001JavaScropt \u306b\u306f\u306a\u304b\u3063\u305f\u578b\u304c\u8a00\u8a9e\u7684\u306b\u30b5\u30dd\u30fc\u30c8\u3055\u308c\u308b\u305f\u3081\u306b\u4e0d\u8981\u306a\u306e\u3067\u524a\u9664\u3057\u3066\u3057\u307e\u3059\n<ul>\n<li>babel-plugin-transform-react-remove-prop-types<\/li>\n<li>prop-types<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2>React \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8 render \u30c6\u30b9\u30c8<\/h2>\n<p>\u3059\u3079\u3066\u306e\u5c0e\u5165\u304c\u3067\u304d\u305f\u306e\u3067\u5b9f\u969b\u306e\u63cf\u753b\u30c6\u30b9\u30c8\u3092\u3057\u307e\u3059\u3002<\/p>\n<p><code>rails g<\/code> \u30b3\u30de\u30f3\u30c9\u3092\u7528\u3044\u3066\u3001\u30b5\u30f3\u30d7\u30eb\u306e Controller \u3068 View \u3092\u4f5c\u6210\u3057\u3001\u305d\u3053\u306b react-rails gem \u306b\u3066\u751f\u6210\u3055\u308c\u305f <code>react_componet<\/code> \u3068\u3044\u3046\u30d8\u30eb\u30d1\u30fc\u30e1\u30bd\u30c3\u30c9\u3092\u5229\u7528\u3057\u3066\u63cf\u753b\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<pre><code># rails g controller Sample index\n# edit app\/views\/sample\/index.html.erb\n&lt;h1&gt;Sample#index&lt;\/h1&gt;\n&lt;p&gt;Find me in app\/views\/sample\/index.html.erb&lt;\/p&gt;\n&lt;%= react_component(&quot;HelloWorld&quot;, { greeting: &quot;Hello from react-rails.&quot; }) %&gt; \u2190\u8ffd\u52a0\n# rails s -b 0.0.0.0\n\u2026\nListening on http:\/\/0.0.0.0:3000<\/code><\/pre>\n<p><img src=\"https:\/\/weseek.co.jp\/tech\/wp-content\/uploads\/2021\/08\/f6d7b64f05ea429f1d0345072b2bfcac.png\" alt=\"\" \/><\/p>\n<ul>\n<li>props \u306b\u3000<code>Hello from react-rails.<\/code> \u3092\u6e21\u3057\u305f\u30b5\u30f3\u30d7\u30eb\u306e\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304c\u63cf\u753b\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/li>\n<\/ul>\n<h2>react_component \u306b\u3064\u3044\u3066<\/h2>\n<p>react-rails gem \u3092\u5c0e\u5165\u3059\u308b\u3068\u306b\u3087\u304d\u306b\u3087\u304d\u751f\u3048\u3066\u304f\u308b <code>react_component<\/code> \u30d8\u30eb\u30d1\u30fc\u30e1\u30bd\u30c3\u30c9\u306b\u3064\u3044\u3066\u8efd\u304f\u8aac\u660e\u3057\u307e\u3059\u3002<\/p>\n<p>\u3068\u306f\u3044\u3048\u3042\u307e\u308a\u8a73\u3057\u3044\u3053\u3068\u3092\u8aac\u660e\u3057\u3066\u3082\u305d\u3053\u307e\u3067\u5f79\u306b\u306f\u7acb\u305f\u306a\u3044\u3068\u601d\u3046\u306e\u3067\u3001\u7c21\u5358\u306b\u8a00\u3046\u3068\u3001\u6307\u5b9a\u3057\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u914d\u4e0b\u306b\u7f6e\u3044\u305f\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306e\u540d\u524d\u3067\u7d10\u3065\u3051\u3066\u3044\u3044\u611f\u3058\u306b ReactDOM.render \u3057\u3066\u304f\u308c\u308b\u3082\u306e\u7a0b\u5ea6\u3067\u5b9f\u52d9\u4e0a\u306f\u554f\u984c\u306a\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u6307\u5b9a\u3057\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3068\u3044\u3046\u306e\u306f\u30c7\u30d5\u30a9\u30eb\u30c8\u3060\u3068 app\/javascript\/components \u914d\u4e0b\u3067\u81ea\u52d5\u7684\u306b application.js \u306b\u8a2d\u5b9a\u304c\u8ffd\u52a0\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<h3>react_component(react-rails) \u3092\u4f7f\u3046\u30e1\u30ea\u30c3\u30c8<\/h3>\n<p>\u5229\u7528\u306e\u30e1\u30ea\u30c3\u30c8\u3092\u6319\u3052\u308b\u3068\u3059\u308b\u3068\u4ee5\u4e0b\u306e3\u70b9\u306e\u3088\u3046\u306a\u3082\u306e\u304c\u3042\u3052\u3089\u308c\u308b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<ul>\n<li>erb(\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8)\u306e render \u3057\u305f\u3044\u5834\u6240\u306b\u76f4\u63a5\u76f4\u611f\u7684\u306b\u66f8\u3051\u308b<\/li>\n<li>erb \u306b\u66f8\u3051\u308b\u305f\u3081\u3001Rails \u304b\u3089 props \u3092\u6e21\u3059\u306e\u304c\u5bb9\u6613<\/li>\n<li>react-rails \u3092\u4f7f\u308f\u306a\u3044\u6642\u306b\u6bd4\u3079\u3066\u8a18\u8ff0\u91cf\u304c\u5c11\u306a\u3044<\/li>\n<\/ul>\n<p>\u30e1\u30ea\u30c3\u30c8\u3060\u3089\u3051\u3060\u3068\u500b\u4eba\u7684\u306b\u306f\u601d\u3044\u307e\u3059\u304c\u3042\u3048\u3066\u30c7\u30e1\u30ea\u30c3\u30c8\u3092\u4e0a\u3052\u308b\u3068\u3059\u308c\u3070\u3001erb \u3068 React \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306e\u5b9a\u7fa9\u304c\u539f\u5247\u5225\u30d5\u30a1\u30a4\u30eb\u304b\u3064\u3001\u660e\u793a\u7684\u306a import \u3068\u304b\u3092\u5fc5\u8981\u3068\u3057\u306a\u3044\u306e\u3067\u7d10\u3065\u3051\u308b\u624b\u639b\u304b\u308a\u304c\u4e21\u65b9\u3079\u305f\u66f8\u304d\u306e\u6587\u5b57\u5217\u306b\u306a\u3063\u3066\u3057\u307e\u3046\u304f\u3089\u3044\u304b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h3>react_component \u3092\u4f7f\u308f\u306a\u3044\u5834\u5408<\/h3>\n<p>\u9006\u306b react_component \u3092\u4f7f\u308f\u306a\u3044\u5834\u5408\u3067\u3059\u304c\u3001\u30c7\u30e1\u30ea\u30c3\u30c8\u3070\u304b\u308a\u66f8\u304f\u3053\u3068\u306b\u306a\u3063\u3066\u3057\u307e\u3044\u307e\u3059\u304c\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u3082\u306e\u304c\u6319\u3052\u3089\u308c\u307e\u3059\u3002<\/p>\n<ul>\n<li>ReactDOM.render \u3092 js \u30d5\u30a1\u30a4\u30eb\u5074\u306b\u66f8\u304b\u306a\u3051\u308c\u3070\u3044\u3051\u306a\u3044<\/li>\n<li>erb \u306a\u3069\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306b\u76f4\u63a5\u66f8\u304b\u306a\u3044\u305f\u3081 render \u3059\u308b\u5834\u6240\u306e\u6307\u5b9a\u304c\u76f4\u89b3\u7684\u3067\u306f\u306a\u3044<\/li>\n<li>erb \u306a\u3069\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306b\u76f4\u63a5\u66f8\u304b\u306a\u3044\u305f\u3081Rails \u5074\u304b\u3089 props \u3092\u52d5\u7684\u306b\u6e21\u3059\u306e\u304c\u82e5\u5e72\u56f0\u96e3<\/li>\n<li>react_component \u3092\u4f7f\u3046\u5834\u5408\u306b\u6bd4\u3079\u3066\u8a18\u8ff0\u91cf\u304c\u591a\u3044<\/li>\n<\/ul>\n<p>\u30e1\u30ea\u30c3\u30c8\u3068\u3057\u3066\u306f\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306e\u5b9a\u7fa9\u3068 render \u304c\u540c\u3058 JavaScropt \u30d5\u30a1\u30a4\u30eb\u306b\u66f8\u304f\u3053\u3068\u306b\u306a\u308b\u306e\u3067\u5148\u307b\u3069\u4f7f\u3046\u5834\u5408\u306e\u30c7\u30e1\u30ea\u30c3\u30c8\u306b\u6319\u3052\u305f\u3001\u7d10\u3065\u3051\u304c\u3079\u305f\u66f8\u304d\u306b\u306a\u308b\u3053\u3068\u306f\u306a\u304f\u3001\u4e00\u5fdc\u88dc\u5b8c\u304c\u52b9\u304f\u3068\u3044\u3046\u30e1\u30ea\u30c3\u30c8\u3082\u306a\u304f\u306f\u306a\u3044\u304b\u306a\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u500b\u4eba\u7684\u306b\u306f\u7d20\u3067\u306f\u4f7f\u308f\u305a react-rails \u307f\u305f\u3044\u306a gem \u3092\u4f7f\u3063\u3066 React \u306e\u63cf\u753b\u3092\u3059\u308b\u306e\u304c\u826f\u3044\u3068\u601d\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<h1>Tips<\/h1>\n<p>\u4e0a\u8a18\u7d39\u4ecb\u3057\u305f\u69cb\u6210\u3092\u5b9f\u969b\u306b\u904b\u7528\u3057\u3066\u307f\u3066\u884c\u3063\u305f\u6539\u5584\u306a\u3069\u3092 Tips \u3068\u3057\u3066\u7d39\u4ecb\u3057\u307e\u3059\u3002<\/p>\n<h2>Rails \u304b\u3089 React \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3078\u306e props \u306e\u6e21\u3057\u65b9<\/h2>\n<h3><a href=\"https:\/\/github.com\/reactjs\/react-rails#7-render-it-in-a-rails-view\">react-rails \u306e\u30b5\u30f3\u30d7\u30eb<\/a>\u306b\u3042\u308b\u4f8b<\/h3>\n<p>react-rails \u306e react_component \u3092\u516c\u5f0f\u306e\u30b5\u30f3\u30d7\u30eb\u901a\u308a\u306b\u4f7f\u304a\u3046\u3068\u3059\u308b\u3068\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<ul>\n<li>erb\n<pre><code>&lt;%= react_component(&quot;HelloWorld&quot;, { greeting: &quot;Hello from react-rails.&quot; }) %&gt;<\/code><\/pre>\n<\/li>\n<li>\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\n<pre><code>type Props = { greeting: string }\nconst HelloWorld: React.VFC&lt;Props&gt; = ({ greeting }) =&gt; &lt;&gt;Greetings: {greeting}&lt;\/&gt;<\/code><\/pre>\n<\/li>\n<\/ul>\n<p><code>greetung<\/code> \u3068\u3044\u3046 string \u306e props \u30921\u3064\u3060\u3051\u53d7\u3051\u53d6\u3063\u3066\u305d\u308c\u3092\u8868\u793a\u3059\u308b\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3067\u3059\u3002<\/p>\n<h3>props \u304c\u5927\u91cf\u306b\u3042\u308b\u5834\u5408\u306e\u4f8b<\/h3>\n<p>props \u304c\u5927\u91cf\u306b\u5897\u3048\u305f\u3089\u3069\u3046\u306a\u308b\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n<pre><code>type Prefecture = &#039;\u6771\u4eac\u90fd&#039; | &#039;\u4eac\u90fd\u5e9c&#039; | &#039;\u5927\u962a\u5e9c&#039; | &#039;\u5317\u6d77\u9053&#039;\n\ntype Props = {\n  username: string\n  email: string\n  age: number\n  prefecture: Prefecture\n  address: string\n  prefectureList: Prefecture[]\n}\n\nconst ProfileForm: React.VFC&lt;Props&gt; = (props) =&gt; {<\/code><\/pre>\n<p>\u4e0a\u8a18\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306f\u30d7\u30ed\u30d5\u30a3\u30fc\u30eb\u3092\u7de8\u96c6\u3059\u308b\u305f\u3081\u306e\u30d5\u30a9\u30fc\u30e0\u3092\u60f3\u50cf\u3057\u3066\u3044\u305f\u3060\u3051\u308c\u3070\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>props \u306b\u306f\u7de8\u96c6\u3059\u308b\u305f\u3081\u306e\u30e6\u30fc\u30b6\u306e\u60c5\u5831\u3068\u3001 prefecture \u306f\u30ea\u30b9\u30c8\u304b\u3089\u9078\u3070\u305b\u305f\u3044\u306e\u3067\u30de\u30b9\u30bf\u3068\u306a\u308b prefectureList \u3092\u53d7\u3051\u53d6\u308b\u3088\u3046\u306a\u8a2d\u8a08\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u5b9f\u969b\u306f\u3053\u3093\u306a\u611f\u3058\u306b\u305f\u304f\u3055\u3093\u306e props \u3092\u30d0\u30e9\u30d0\u30e9\u3068\u53d7\u3051\u53d6\u3089\u305a\u3001\u30e2\u30c7\u30eb\u3084\u307e\u3068\u3081\u305f Object \u3068\u304b\u3092\u6e21\u3059\u304b\u3068\u601d\u3044\u307e\u3059\u304c\u3042\u304f\u307e\u3067\u3082\u4f8b\u3067\u3059\u3002<\/p>\n<h4>\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u5229\u7528\u3059\u308b\u305f\u3081\u306e\u30c7\u30fc\u30bf\u3001\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u7528\u610f<\/h4>\n<p>\u5b9f\u969b\u306b\u30b5\u30f3\u30d7\u30eb\u3067\u7528\u610f\u3057\u305f props \u3092\u5927\u91cf\u306b\u53d7\u3051\u53d6\u308b\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u5229\u7528\u3059\u308b\u305f\u3081\u306e\u6e96\u5099\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>\u3053\u3061\u3089\u306f\u7d14\u7c8b\u306a Rails \u306e\u307f\u306e\u6a5f\u80fd\u306a\u306e\u3067\u8aac\u660e\u306f\u5272\u611b\u3055\u305b\u3066\u3044\u305f\u3060\u304d\u307e\u3059<\/p>\n<ul>\n<li>\u30b5\u30f3\u30d7\u30eb\u7528\u306b Prefecture, User \u30e2\u30c7\u30eb\u3092\u5b9a\u7fa9\n<pre><code>rails g model Prefecture name:string\nrails g model User name:string email:string age:integer address:string prefecture:references\nrails db:migrate<\/code><\/pre>\n<\/li>\n<li>\u30c7\u30fc\u30bf\u6295\u5165\n<pre><code>rails c\n> Prefecture.create(name: &#039;\u6771\u4eac\u90fd&#039;)\n> Prefecture.create(name: &#039;\u4eac\u90fd\u5e9c&#039;)\n> Prefecture.create(name: &#039;\u5927\u962a\u5e9c&#039;)\n> Prefecture.create(name: &#039;\u5317\u6d77\u9053&#039;)\n> User.create(name: &#039;haruhiko&#039;, email: &#039;haruhiko@weseek.co.jp&#039;, age: 30, address: &#039;\u9ad8\u7530\u99ac\u5834&#039;, prefecture: Prefecture.first)<\/code><\/pre>\n<\/li>\n<li>\n<p>controller \u7de8\u96c6<\/p>\n<pre><code>class SampleController &lt; ApplicationController\ndef index\n@prefecture_list = Prefecture.pluck(:name)\n# [&quot;\u6771\u4eac\u90fd&quot;, &quot;\u4eac\u90fd\u5e9c&quot;, &quot;\u5927\u962a\u5e9c&quot;, &quot;\u5317\u6d77\u9053&quot;]\n\n@user = User.find_by(name: &#039;haruhiko&#039;)\n# id: 1,\n# name: &quot;haruhiko&quot;,\n# email: &quot;haruhiko@weseek.co.jp&quot;,\n# age: 30,\n# address: &quot;\u9ad8\u7530\u99ac\u5834&quot;,\n# prefecture_id: 1,\n# created_at: Fri, 13 Aug 2021 00:40:29.546785000 UTC +00:00,\n# updated_at: Fri, 13 Aug 2021 00:40:29.546785000 UTC +00:00\nend\nend<\/code><\/pre>\n<\/li>\n<\/ul>\n<h4>View<\/h4>\n<pre><code>&lt;%= react_component(&quot;ProfileForm&quot;, {\n  username: @user.username,\n  email: @user.email,\n  age: @user.age,\n  prefecture: @user.prefecture.name,\n  address: @user.address,\n  prefectureList: @prefecture_list \n}) %&gt;<\/code><\/pre>\n<p>\u3053\u306e\u304f\u3089\u3044\u3067\u3042\u308c\u3070\u307e\u3060\u8a31\u5bb9\u7bc4\u56f2\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u304c\u3001\u3053\u306e\u3088\u3046\u306b\u3059\u3079\u3066\u306e props \u306b\u5bfe\u3057\u3066\u4e00\u3064\u4e00\u3064\u5024\u3092\u6e21\u3055\u306a\u3051\u308c\u3070\u3044\u3051\u306a\u304f\u306a\u308a\u3001\u4e2d\u8eab\u304c\u8907\u96d1\u306b\u306a\u308c\u3070\u306a\u308b\u307b\u3069\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u304c\u3054\u3061\u3083\u3054\u3061\u3083\u3057\u3066\u304d\u307e\u3059\u3002<\/p>\n<h3><a href=\"https:\/\/github.com\/rails\/jbuilder\">Jbuilder gem<\/a> \u3092\u5229\u7528\u3059\u308b<\/h3>\n<p>\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u304c\u3054\u3061\u3083\u3054\u3061\u3083\u3059\u308b\u554f\u984c\u3092\u89e3\u6d88\u3059\u308b\u306b\u306f Rails \u3092\u4f7f\u3063\u3066\u308b\u4eba\u306b\u306f\u304a\u306a\u3058\u307f\u306e <a href=\"https:\/\/github.com\/rails\/jbuilder\">Jbuilder gem<\/a> \u3092\u4f7f\u3046\u3068\u3001\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306b props \u306e\u5b9a\u7fa9\u3092\u66f8\u304f\u5fc5\u8981\u304c\u306a\u304f\u306a\u308a\u8a18\u8ff0\u304c\u30b9\u30c3\u30ad\u30ea\u3059\u308b\u3060\u3051\u3067\u306f\u306a\u304f\u3001props \u306e\u6210\u5f62\u306f\u5c02\u7528\u306e\u30e9\u30a4\u30d6\u30e9\u30ea\u3078\u3068\u8cac\u52d9\u306e\u79fb\u8b72\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u5148\u307b\u3069\u306e View \u3092\u66f8\u304d\u76f4\u3059\u3068\u3053\u3093\u306a\u611f\u3058\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre><code># \/app\/views\/sample\/_profile_component.json.jbuilder\n\njson.username @user.username\njson.email @user.email\njson.age @user.age\njson.address @user.address\njson.prefecture @user.prefecture\njson.prefectureList @prefecture_list<\/code><\/pre>\n<pre><code>&lt;%= react_component(&quot;ProfileForm&quot;, render(template: &#039;sample\/_profile_component.json&#039;)) %&gt;<\/code><\/pre>\n<h3>User \u306e\u60c5\u5831\u3092\u4e00\u3064\u306e Object \u306b\u307e\u3068\u3081\u308b\u5834\u5408\u3068\u6ce8\u610f\u70b9<\/h3>\n<p>\u5b9f\u969b\u306b\u30b3\u30fc\u30c9\u3092\u66f8\u304f\u969b\u306b\u306f\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306b Rails \u5074\u3067\u751f\u6210\u3057\u305f User \u30e2\u30c7\u30eb\u3092\u3072\u3068\u56fa\u307e\u308a\u3068\u3057\u3066\u3001React \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u5074\u3067 ViewModel \u307f\u305f\u3044\u306a\u3082\u306e\u3092\u5b9a\u7fa9\u3059\u308b\u5834\u5408\u304c\u591a\u3044\u304b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<pre><code>type PrefectureName = &#039;\u6771\u4eac\u90fd&#039; | &#039;\u4eac\u90fd\u5e9c&#039; | &#039;\u5927\u962a\u5e9c&#039; | &#039;\u5317\u6d77\u9053&#039;\ntype User = { username: string; email: string; age: number; prefecture: PrefectureName; address: string }\n\ntype Props = { user: User; prefectureList: PrefectureName[] }\nconst ProfileForm: React.VFC&lt;Props&gt; = ({ user, prefecrureList }) =&gt; {<\/code><\/pre>\n<p>\u3053\u306e\u5834\u5408\u306e Jbuilder<\/p>\n<pre><code>json.user do\n  json.extract! @user, :username, :email, :age, :address\n  json.prefecture @user.prefecture.name\nend\njson.prefectureList @prefecture_list<\/code><\/pre>\n<p>jbuilder \u306e\u66f8\u304d\u65b9\u306e\u8a71\u3067\u3059\u304c <code>extract!<\/code> \u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u3044\u3001\u5fc5\u8981\u306a\u30ab\u30e9\u30e0\u306e\u307f\u3092 user \u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u304b\u3089\u629c\u304d\u51fa\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u5b9f\u306f\u3053\u306e\u5834\u5408 erb \u5074\u306b\u66f8\u304f <code>react_component<\/code> \u30e1\u30bd\u30c3\u30c9\u306b\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306b user \u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u76f4\u63a5\u6e21\u3057\u3066\u3082\u53d7\u3051\u53d6\u308b\u5074\u306e\u69cb\u9020\u304c\u4e00\u81f4\u3059\u308c\u3070\u63cf\u753b\u3059\u308b\u3053\u3068\u304c\u53ef\u80fd\u3067\u3059\u3002<\/p>\n<pre><code>&lt;%= react_component(&quot;ProfileForm&quot;, {\n  user: @user,\n  prefectureList: @prefecture_list \n}) %&gt;<\/code><\/pre>\n<p>\u3057\u304b\u3057\u3053\u306e\u5834\u5408 <code>@user<\/code> \u306e\u4e2d\u8eab\u306b\u306f <code>id<\/code> \u3084 <code>created_at<\/code> \u306a\u3069\u306e\u63cf\u753b\u306b\u5fc5\u8981\u306e\u306a\u3044\u5024\u307e\u3067\u5165\u3063\u3066\u3057\u307e\u3063\u3066\u3044\u3066\u3001\u3053\u308c\u3089\u306e\u5024\u306f javascript \u306e\u4e2d\u306b\u542b\u307e\u308c\u3066\u3057\u307e\u3046\u305f\u3081\u3001\u30d6\u30e9\u30a6\u30b6\u306e\u30c7\u30d9\u30ed\u30c3\u30d1\u30fc\u30c4\u30fc\u30eb\u306a\u3069\u3092\u4f7f\u3048\u3070\u9664\u304f\u3053\u3068\u304c\u53ef\u80fd\u3067\u3059\u3002<\/p>\n<p>\u3057\u305f\u304c\u3063\u3066\u4eca\u56de\u306e\u4f8b\u306f\u5225\u306b\u6f0f\u308c\u3066\u3082\u305d\u3053\u307e\u3067\u554f\u984c\u306b\u306f\u306a\u3089\u306a\u3044\u306e\u3067\u3059\u304c\u3001\u3082\u3057\u6e21\u3059\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u30ab\u30e9\u30e0\u306e\u4e2d\u306b IP \u30a2\u30c9\u30ec\u30b9\u3084\u30d1\u30b9\u30ef\u30fc\u30c9\u3001token \u306a\u3069\u306e\u79d8\u533f\u60c5\u5831\u304c\u542b\u307e\u308c\u3066\u3044\u305f\u5834\u5408\u60c5\u5831\u6f0f\u6d29\u306b\u3064\u306a\u304c\u308b\u306e\u3067\u6c17\u3092\u4ed8\u3051\u306a\u3051\u308c\u3070\u3044\u3051\u307e\u305b\u3093\u3002<\/p>\n<p>\u306a\u306e\u3067\u3001Jbuilder \u306e\u3088\u3046\u306a JSON \u6210\u5f62\u306e\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u5fc5\u305a\u901a\u3059\u3088\u3046\u306b\u3057\u3066\u5fc5\u8981\u306a\u30ab\u30e9\u30e0\u306e\u307f\u3092\u629c\u304d\u51fa\u3057\u3066 props \u306b\u6e21\u3057\u3066\u3042\u3052\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<h2>\u304a\u3059\u3059\u3081\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u69cb\u6210<\/h2>\n<p>\u57fa\u672c\u7684\u306b\u306f Rails \u6a19\u6e96\u53ca\u3073\u3001webpacker:install \u3057\u3066\u51fa\u6765\u305f\u901a\u308a\u306b\u4f7f\u3063\u3066\u3044\u3066\u3001\u4e2d\u3067\u3082\u5fc5\u8981\u3060\u3068\u601d\u3044\u72ec\u81ea\u306b\u4f5c\u6210\u3057\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u7d39\u4ecb\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>\u3068\u306f\u3044\u3048\u4eca\u56de\u7d39\u4ecb\u3059\u308b\u306e\u306f <code>\/app\/javascript\/components<\/code> \u914d\u4e0b\u306e\u307f\u3067\u3059\u3002<\/p>\n<p>\u4ed6\u306b\u3082 <code>services<\/code> \u3068\u3044\u3063\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u5207\u3063\u3066\u30b5\u30fc\u30d3\u30b9\u5c64\u306e\u8ffd\u52a0\u306a\u3069\u3092\u3084\u3063\u3066\u306f\u3044\u308b\u306e\u3067\u3059\u304c\u3001\u3053\u3061\u3089\u306f Rails \u306e\u4e2d\u3067\u5b8c\u7d50\u3057\u3001\u4eca\u56de\u306f\u95a2\u4fc2\u306a\u3044\u306e\u3067\u5272\u611b\u3057\u307e\u3059\u3002<\/p>\n<h3>components \u914d\u4e0b<\/h3>\n<p>\u30c7\u30d5\u30a9\u30eb\u30c8\u3060\u3068 <code>\/app\/javascript\/components<\/code> \u3068\u3044\u3046\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u304c\u305f\u3060\u4e00\u3064\u4f5c\u6210\u3055\u308c\u308b\u306e\u307f\u3067\u3001\u6700\u521d\u306f\u305d\u306e\u4e2d\u306b\u4f55\u3068\u306a\u304f\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u5207\u3063\u3066\u9069\u5f53\u306b\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u5165\u308c\u3066\u3044\u307e\u3057\u305f\u3002<\/p>\n<p>\u305d\u3046\u3059\u308b\u3068\u305d\u3053\u305d\u3053\u7121\u79e9\u5e8f\u306b\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3084\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306e\u6570\u3005\u304c\u5897\u3048\u3066\u3044\u304d\u7ba1\u7406\u304c\u5927\u5909\u306b\u306a\u3063\u3066\u304d\u307e\u3057\u305f\u3002<\/p>\n<p>\u305d\u3053\u3067components \u306e\u914d\u4e0b\u306b\u65b0\u3057\u304f\u4ee5\u4e0b\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f\u3002<\/p>\n<ul>\n<li>pages<\/li>\n<li>commons<\/li>\n<\/ul>\n<h4>pages \u914d\u4e0b<\/h4>\n<p>pages \u306e\u914d\u4e0b\u306f\u4ee5\u4e0b\u306e\u30eb\u30fc\u30eb\u3067\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u7f6e\u3044\u3066\u3044\u307e\u3059\u3002<\/p>\n<ul>\n<li>pages \u914d\u4e0b\u306b\u7f6e\u3044\u305f\u3082\u306e\u306f\u539f\u5247 erb \u304b\u3089\u306e\u307f\u547c\u3073\u51fa\u3059<\/li>\n<li>\u3044\u308f\u3086\u308b\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3068\u3057\u3066\u306e\u90e8\u54c1\u3067\u306f\u306a\u304f page \u5168\u4f53\u3092\u69cb\u6210\u3059\u308b\u3082\u306e\n<ul>\n<li>\u901a\u5e38 MPA \u3067\u3042\u308b Rails \u3067\u306f\u3042\u308b\u304c\u3001React \u3092\u4f7f\u3063\u305f SPA \u307f\u305f\u3044\u306a\u52d5\u304d\u3092\u3059\u308b\u30da\u30fc\u30b8\u306e root \u306b\u306a\u308b\u3088\u3046\u306a\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8<\/li>\n<li>next.js \u306b\u304a\u3051\u308b pages \u914d\u4e0b\u306b\u914d\u7f6e\u3055\u308c\u308b\u3088\u3046\u306a\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8<\/li>\n<\/ul>\n<\/li>\n<li>pages \u914d\u4e0b\u306b\u7f6e\u3044\u305f\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3068\u540c\u540d\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u5207\u308b\u3053\u3068\u3082\u3042\u308b\n<ul>\n<li>\u914d\u4e0b\u306b\u306f\u305d\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u540d\u306e\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304b\u3089\u3057\u304b\u547c\u3073\u51fa\u3055\u308c\u306a\u3044\u3053\u3068\u304c\u78ba\u5b9a\u3057\u3066\u3044\u308b\u3088\u3046\u306a\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u7f6e\u304f<\/li>\n<li>UserForm \u3068\u3044\u3046\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304c\u3042\u308c\u3070 UserForm \u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u914d\u4e0b\u306b\u306f UserForm \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304b\u3089\u98f2\u307f\u547c\u3073\u51fa\u3055\u308c\u308b\u3088\u3046\u306a\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304c\u7f6e\u304b\u308c\u308b\n<ul>\n<li>pages\/UserForm.tsx<\/li>\n<li>pages\/UserForm\/UserNameFormInput.tsx<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h4>commons \u914d\u4e0b<\/h4>\n<ul>\n<li>\u3042\u3089\u3086\u308berb\u3001\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304b\u3089\u4e00\u90e8\u54c1\u3068\u3057\u3066\u547c\u3070\u308c\u308b\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\n<ul>\n<li>commons\/badge\/UseBadge.tsx<br \/>\n<img src=\"https:\/\/weseek.co.jp\/tech\/wp-content\/uploads\/2021\/08\/d84789533040312f58fb0feb163c05cc.png\" alt=\"\" \/><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>\u3053\u306e\u753b\u50cf\u306e\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306f\u5b9f\u969b\u306b\u696d\u52d9\u3067\u4f7f\u3063\u3066\u308b\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3067\u3042\u3089\u3086\u308b\u3068\u3053\u308d\u304b\u3089\u547c\u3070\u308c\u3066\u5229\u7528\u3055\u308c\u3066\u3044\u308b\u30d0\u30c3\u30b8\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3067\u3059\u3002<\/p>\n<p>\u4ed6\u306b\u3082\u30c7\u30b6\u30a4\u30f3\u3092\u5171\u901a\u5316\u3057\u305f\u3044\u3088\u3046\u306a\u30d5\u30a9\u30fc\u30e0\u306e\u90e8\u54c1\u3067\u3042\u3063\u305f\u308a\u30dc\u30bf\u30f3\u3068\u304b\u5272\u3068\u5927\u90e8\u5206\u304c\u5165\u3063\u3066\u304f\u308b\u3068\u601d\u3044\u307e\u3059\u3002\u305d\u306e\u305f\u3081\u306b\u30d0\u30c3\u30b8\u307f\u305f\u3044\u306a\u30b5\u30d6\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u304c\u5207\u3089\u308c\u308b\u3053\u3068\u304c\u591a\u3044\u3067\u3057\u3087\u3046\u3002<\/p>\n<h1>\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u306b\u3064\u3044\u3066<\/h1>\n<p>\u6700\u5f8c\u306b\u4eca\u56de\u7d39\u4ecb\u3057\u305f Rails \u306e\u4e0a\u306b React \u3092\u4e57\u305b\u308b\u5834\u5408\u3068\u3001\u8a73\u3057\u304f\u306f\u8aac\u660e\u3057\u307e\u305b\u3093\u3067\u3057\u305f\u304c\u6bd4\u8f03\u306e\u305f\u3081\u306b Rails \u3068 React \u3092\u5225\u3005\u306b\u5206\u96e2\u3059\u308b\u5834\u5408\u306e\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u306e\u8aac\u660e\u3068\u6bd4\u8f03\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u9078\u5b9a\u306e\u52a9\u3051\u306b\u306a\u308c\u3070\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h2>Rails \u306e\u4e0a\u306b React \u3092\u4e57\u305b\u308b\u5834\u5408<\/h2>\n<p>\u5168\u4f53\u7684\u306a\u69cb\u6210\u306e\u6982\u8981\u306f\u4e00\u756a\u6700\u521d\u306e <a href=\"#\">\u69cb\u6210\u306e\u6982\u8981<\/a> \u3092\u53c2\u7167\u304f\u3060\u3055\u3044\u3002<\/p>\n<h3>\u30e1\u30ea\u30c3\u30c8<\/h3>\n<p>\u6700\u521d\u306e\u6982\u8981\u306e\u8aac\u660e\u3067\u3082\u3057\u305f\u901a\u308a\u3001Rails \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3092\u4f5c\u6210\u3059\u308b\u3053\u3068\u306b\u306a\u308b\u306e\u3067\u305d\u308c\u306b\u3061\u306a\u3093\u3060\u30e1\u30ea\u30c3\u30c8\u304c\u591a\u3044\u3068\u601d\u308f\u308c\u307e\u3059\u3002<\/p>\n<ul>\n<li>Rails \u306e\u6a5f\u80fd\u306e\u307b\u3068\u3093\u3069\u3092\u30d9\u30fc\u30b9\u306b React \u3092\u4f7f\u3046\u3053\u3068\u306b\u306a\u308b\n<ul>\n<li>\u65e2\u5b58\u306e Rails \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306b\u3061\u3087\u3044\u8db3\u3057\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u308b<\/li>\n<li>\u65e2\u5b58\u306e Rails \u306e\u77e5\u8b58\u304c\u307b\u307c\u3059\u3079\u3066\u6d3b\u304b\u3059\u3053\u3068\u304c\u3067\u304d\u308b<\/li>\n<\/ul>\n<\/li>\n<li>Rails \u306e\u8a8d\u8a3c\u57fa\u76e4\u304c\u305d\u306e\u307e\u307e\u5229\u7528\u3067\u304d\u308b\n<ul>\n<li>\u5206\u96e2\u3057\u305f\u5834\u5408\u306b\u306f\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u30a2\u30d7\u30ea\u3068\u306e\u3064\u306a\u304e\u8fbc\u307f\u3092\u8003\u616e\u3057\u306a\u3051\u308c\u3070\u306a\u3044\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>\u4e2d\u3067\u3082\u65e2\u5b58\u306e Rails \u304c\u4f7f\u3048\u308b\u3068\u3044\u3046\u3053\u3068\u306f\u6614\u304b\u3089\u5b58\u5728\u3059\u308b Rails \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u62e1\u5f35\u3059\u308b\u3053\u3068\u304c\u53ef\u80fd\u3068\u3044\u3046\u3053\u3068\u306a\u306e\u3067\u3001\u4eca\u307e\u3067\u306e\u8cc7\u6e90\u3092\u4f59\u3059\u3053\u3068\u306a\u304f\u5229\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<h3>\u30c7\u30e1\u30ea\u30c3\u30c8<\/h3>\n<ul>\n<li>Rails \u306e\u4e0a\u306b React \u3068\u3044\u3046\u5168\u304f\u5225\u306e\u7269\u304c\u4e57\u308b\n<ul>\n<li>Ruby \u3067\u306f\u306a\u304f JavaScript \u306e\u30e9\u30a4\u30d6\u30e9\u30ea<\/li>\n<li>Rails \u306e\u5f31\u3044\u3068\u3053\u308d\u3067\u3042\u308b View \u5c64\n<ul>\n<li>\u305d\u308c\u3092\u88dc\u3046\u306f\u305a\u3060\u3063\u305f Webpacker \u7279\u6709\u306e\u8af8\u3005<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>Next.js \u3068\u3044\u3063\u305f \u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u304c\u539f\u5247\u4f7f\u3048\u306a\u3044\n<ul>\n<li>SPA \u304c\u4f5c\u308a\u3065\u3089\u3044<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p>\u30c7\u30e1\u30ea\u30c3\u30c8\u3068\u3057\u3066\u500b\u4eba\u7684\u306b\u4e00\u756a\u5927\u304d\u3044\u3068\u601d\u3063\u3066\u3044\u308b\u306e\u304c2\u756a\u76ee\u306b\u6319\u3052\u305f\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u304c\u5229\u7528\u3067\u304d\u306a\u3044\u3068\u3053\u308d\u3060\u3068\u601d\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u3084\u306f\u308a\u9905\u306f\u9905\u5c4b\u3067\u3042\u3063\u3066\u3001\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u3092\u5c02\u9580\u306b\u8003\u3048\u3089\u308c\u3066\u4f5c\u3089\u308c\u308b\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306e\u307b\u3046\u304c\u6280\u8853\u7684\u306b\u767a\u5c55\u304c\u65e9\u304b\u3063\u305f\u308a\u9ad8\u5ea6\u3067\u3042\u308b\u3053\u3068\u304c\u591a\u3044\u306e\u3067\u305d\u306e\u6069\u6075\u3092\u53d7\u3051\u3065\u3089\u3044\u306e\u306f\u3082\u3063\u305f\u3044\u306a\u3044\u306a\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u307e\u305f Webpacker \u3067\u3059\u304c\u3053\u3061\u3089\u3082\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3092\u3057\u3088\u3046\u3068\u3059\u308b\u3068\u7656\u304c\u5f37\u304f\u3001\u7686\u82e6\u52b4\u3057\u3066\u3044\u308b\u3068\u3044\u3046\u5370\u8c61\u3092\u53d7\u3051\u307e\u3059\u3002\u3068\u306f\u3044\u3048 React \u3092\u4f7f\u3048\u308b\u3088\u3046\u306b\u5c0e\u5165\u3059\u308b\u3060\u3051\u3067\u3042\u308c\u3070\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u8a2d\u5b9a\u3067\u3082\u554f\u984c\u306f\u306a\u304f\u3001\u3053\u306e\u554f\u984c\u306b\u76f4\u9762\u3059\u308b\u306e\u306f\u4f55\u304b\u51dd\u3063\u305f\u3053\u3068\u3092\u3084\u308a\u305f\u304f\u306a\u308b\u6642\u304b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h2>Rails \u3068 React \u3092\u5225\u3005\u306b\u5206\u96e2\u3059\u308b\u5834\u5408<\/h2>\n<h3>\u69cb\u6210\u306e\u6982\u8981<\/h3>\n<p><img src=\"https:\/\/weseek.co.jp\/tech\/wp-content\/uploads\/2021\/08\/a5cab224753d9831fed2c6ee06c8bb89.png\" alt=\"\" \/><\/p>\n<p>\u5148\u307b\u3069\u306f\u5168\u90e8 Rails \u306e\u67a0\u306e\u4e2d\u306b\u3059\u3079\u3066\u3092\u4e57\u3063\u3051\u3066\u3044\u305f\u306e\u3067\u3059\u304c\u3001\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u30a2\u30d7\u30ea\u3001\u3064\u307e\u308a\u30d6\u30e9\u30a6\u30b6\u3067\u52d5\u304b\u3059\u3082\u306e\u3068\u3001Rails(API\u30b5\u30fc\u30d0\uff09\u3068\u3057\u3066\u5206\u96e2\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u30a2\u30d7\u30ea\u306e JavaScript \u304b\u3089 Rails \u306e API \u3092\u547c\u3073\u51fa\u3057 Rails \u306e API \u306f\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u304b\u3089\u30ea\u30af\u30a8\u30b9\u30c8\u3092\u53d7\u3051\u53d6\u3063\u305f\u3089 Jbuilder \u306a\u3069\u3067 JSON \u3092\u6210\u5f62\u3057\u3066 JSON \u3092\u8fd4\u3059\u3068\u3044\u3046\u6d41\u308c\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<h3>\u30e1\u30ea\u30c3\u30c8<\/h3>\n<p>\u30e1\u30ea\u30c3\u30c8\u3068\u3057\u3066\u306f\u4f55\u3088\u308a\u3082\u5206\u96e2\u3092\u3057\u3066\u3044\u308b\u306e\u3067\u4e92\u3044\u306b\u5f97\u610f\u306a\u3053\u3068\u3078\u5fb9\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3068\u3044\u3046\u70b9\u306b\u3042\u308b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<ul>\n<li>Rails \u3067\u306f API \u306e\u63d0\u4f9b\u306b\u96c6\u4e2d<\/li>\n<li>\u30d5\u30ed\u30f3\u30c8\u306f\u30e2\u30c0\u30f3\u306a\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306e\u5229\u7528\u304c\u3067\u304d\u308b<\/li>\n<li>\u8a55\u5224\u306e\u826f\u304f\u306a\u3044 Webpacker \u3092\u89e6\u308b\u5fc5\u8981\u304c\u7121\u3044\n<ul>\n<li>\u751f\u306e Webpack \u3082\u305d\u308c\u306f\u305d\u308c\u3067\u30c4\u30e9\u3044\u304c\u3002\u3002\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\/\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u306e\u5206\u696d\u304c\u5bb9\u6613<\/li>\n<\/ul>\n<p>\u6319\u3052\u305f\u901a\u308a\u9905\u306f\u9905\u5c4b\u3067\u3042\u308a\u3001\u305d\u308c\u306f\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306f\u3082\u3061\u308d\u3093\u306e\u3053\u3068\u30a8\u30f3\u30b8\u30cb\u30a2\u306e\u5206\u696d\u3082\u6bd4\u8f03\u7684\u53ef\u80fd\u306b\u306a\u308b\u306e\u3067\u305d\u308c\u305e\u308c\u306e\u30b9\u30da\u30b7\u30e3\u30ea\u30b9\u30c8\u304c\u62c5\u5f53\u3057\u3001\u958b\u767a\u30b9\u30d4\u30fc\u30c9\u3092\u4e0a\u3052\u308b\u3068\u3044\u3063\u305f\u6226\u7565\u3092\u53d6\u308b\u3053\u3068\u3082\u53ef\u80fd\u306b\u306a\u308b\u3067\u3057\u3087\u3046\u3002<\/p>\n<h3>\u30c7\u30e1\u30ea\u30c3\u30c8<\/h3>\n<p>\u30e1\u30ea\u30c3\u30c8\u306e\u9805\u3067\u306f\u5206\u96e2\u3059\u308b\u3053\u3068\u304c\u30e1\u30ea\u30c3\u30c8\u3068\u7d39\u4ecb\u3057\u307e\u3057\u305f\u304c\u3001\u5206\u96e2\u3055\u308c\u3066\u308b\u304b\u3089\u3053\u305d\u306e\u30c7\u30e1\u30ea\u30c3\u30c8\u304c\u3042\u3052\u3089\u308c\u307e\u3059\u3002<\/p>\n<ul>\n<li>\u30ea\u30dd\u30b8\u30c8\u30ea\u304c\u5897\u3048\u305f\u308a\u3001\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u304c\u5897\u3048\u305f\u308a\u3059\u308b<\/li>\n<li>Rails \u3068 \u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u4e8c\u3064\u306e\u6280\u8853\u3092\u4f7f\u3046\u306e\u3067\u5b66\u7fd2\u30b3\u30b9\u30c8\u304c\u9ad8\u3044\uff08\u304b\u3082\uff09\u3057\u308c\u306a\u3044\n<ul>\n<li>\u304b\u3082\u3068\u3044\u3046\u306e\u306f Rails \u306b\u4e57\u305b\u305f\u5834\u5408\u3082\u7d50\u5408\u3059\u308b\u305f\u3081\u306e Webpacker \u306a\u3069\u72ec\u81ea\u306e\u30eb\u30fc\u30eb\u306b\u5bfe\u3059\u308b\u5b66\u7fd2\u30b3\u30b9\u30c8\u304c\u304b\u304b\u3063\u3066\u304f\u308b\u306e\u306b\u4e00\u6982\u306b\u3082\u3069\u3061\u3089\u304c\u9ad8\u3044\u3068\u306f\u8a00\u3048\u306a\u3044<\/li>\n<\/ul>\n<\/li>\n<li>\u5206\u696d\u304c\u51fa\u6765\u3066\u3082\u30b3\u30df\u30e5\u30cb\u30b1\u30fc\u30b7\u30e7\u30f3\u30b3\u30b9\u30c8\u304c\u5897\u3048\u308b\u3053\u3068\u3082\u3042\u308b\n<ul>\n<li>\u5206\u96e2\u3055\u308c\u305f\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u306e\u7d50\u5408\u90e8\u5206\u306e\u8abf\u6574<\/li>\n<\/ul>\n<\/li>\n<li>\u8a8d\u8a3c\u304c\u5fc5\u8981\u306a\u5834\u5408\u5de5\u592b\u304c\u5fc5\u8981\u306b\u306a\u308b\n<ul>\n<li>API \u30b5\u30fc\u30d0\u3068\u306f http \u3067\u3084\u308a\u53d6\u308a\u3092\u3059\u308b\u305f\u3081\u8a8d\u8a3c\u60c5\u5831\u306f JWT \u3084 Cookie \u3092\u4f7f\u3063\u305f\u308a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308b<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2>\u307e\u3068\u3081<\/h2>\n<p>\u3053\u3093\u306a\u611f\u3058\u306b\u3069\u306e\u69cb\u6210\u3092\u53d6\u308d\u3046\u3068\u3082\u30e1\u30ea\u30c3\u30c8\u30c7\u30e1\u30ea\u30c3\u30c8\u304c\u3042\u308a\u3001\u6b63\u89e3\u306f\u5b58\u5728\u3057\u306a\u3044\u306e\u304b\u306a\u3068\u601d\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u500b\u4eba\u7684\u306b\u306f\u5404\u3005\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306e\u5f37\u3044\u3068\u3053\u308d\u3092\u6700\u5927\u9650\u306b\u751f\u304b\u305b\u308b\u5206\u96e2\u578b\u304c\u597d\u304d\u306a\u3093\u3067\u3059\u304c\u3001\u305d\u3053\u307e\u3067\u5927\u898f\u6a21\u306b\u306a\u3089\u306a\u3044\u3088\u3046\u306a\u7c21\u5358\u306a\u30a2\u30d7\u30ea\u3060\u3063\u305f\u308a\u3001\u3082\u3068\u3082\u3068\u306e Rails \u30a2\u30d7\u30ea\u3092\u5f15\u304d\u7d99\u304c\u306a\u304d\u3083\u3044\u3051\u306a\u3044\u7406\u7531\u3068\u304b\u304c\u3042\u308b\u5834\u5408\u306f\u4e0a\u306b\u4e57\u3063\u3051\u308b\u5f62\u3067\u3082\u5168\u7136\u30a2\u30ea\u3060\u306a\u3068\u3053\u306e\u767a\u8868\u3067\u3044\u308d\u3044\u308d\u8abf\u3079\u3066\u3044\u308b\u3046\u3061\u306b\u601d\u3048\u3066\u306f\u304d\u307e\u3057\u305f\u3002<\/p>\n<p>\u7d50\u5c40\u3069\u306e\u69cb\u6210\u3092\u53d6\u308d\u3046\u3068\u3082\u30e1\u30ea\u30c3\u30c8\u3068\u30c7\u30e1\u30ea\u30c3\u30c8\u306f\u5b58\u5728\u3059\u308b\u306e\u3067\u6700\u7d42\u7684\u306b\u306f\u3069\u306e\u30e1\u30ea\u30c3\u30c8\u304c\u597d\u304d\u306a\u306e\u304b\u3001\u4f5c\u6210\u3059\u308b\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3084\u30c1\u30fc\u30e0\u306b\u5408\u3063\u3066\u3044\u308b\u306e\u304b\u3068\u3044\u3046\u90e8\u5206\u3060\u3068\u601d\u3046\u306e\u3067\u3001\u3069\u308c\u304c\u6b63\u89e3\u3060\u3068\u6c7a\u3081\u3064\u3051\u306f\u305b\u305a\u67d4\u8edf\u306b\u691c\u8a0e\u3057\u3066\u3044\u304b\u306a\u3051\u308c\u3070\u306a\u3089\u306a\u3044\u3068\u601d\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<h3>\u8457\u8005\u30d7\u30ed\u30d5\u30a3\u30fc\u30eb<\/h3>\n<p><a href=\"https:\/\/github.com\/haruhikonyan\">\u5927\u8c37 \u6771\u5f66<\/a><\/p>\n<p>\u682a\u5f0f\u4f1a\u793eWESEEK \/ \u30b7\u30b9\u30c6\u30e0\u30a8\u30f3\u30b8\u30cb\u30a2<\/p>\n<p>\u6587\u7cfb\u5b66\u79d1\u5352\u696d\u5f8c\u3001\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u307b\u307c\u672a\u7d4c\u9a13\u3067\u5927\u624b SIer \u306b\u5165\u793e\u3002 \u30a4\u30f3\u30d5\u30e9\u30a8\u30f3\u30b8\u30cb\u30a2\u30922\u5e74\u534a\u307b\u3069\u7d4c\u9a13\u3002<\/p>\n<p>2015\u5e7411\u6708WESEEK\u306b\u5165\u793e\u3057\u672c\u683c\u7684\u306b WEB \u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3092\u59cb\u3081\u308b\u3002<\/p>\n<p>\u524d\u8077\u306e\u7d4c\u9a13\u3092\u6d3b\u304b\u3057\u3064\u3064\u3001\u30a4\u30f3\u30d5\u30e9\u304b\u3089\u30d5\u30ed\u30f3\u30c8\u30a8\u30f3\u30c9\u307e\u3067\u4f55\u3067\u3082\u3053\u306a\u3059\u81ea\u79f0\u30d5\u30eb\u30b9\u30bf\u30c3\u30af\u30a8\u30f3\u30b8\u30cb\u30a2\u3002<\/p>\n<p>\u4f1a\u793e\u306e slack \u306b\u5e38\u99d0\u3057\u3001\u9032\u6357\u3092\u3072\u305f\u3059\u3089\u5782\u308c\u6d41\u3059\u65e5\u3005\u3092\u9001\u308b\u3002\u6700\u8fd1\u306f\u30ec\u30d3\u30e5\u30fc\u306b\u3082\u529b\u3092\u5165\u308c\u3001\u5f8c\u9032\u306e\u80b2\u6210\u306b\u3082\u52b1\u3093\u3067\u3044\u308b\u3002<\/p>\n<h2>\u682a\u5f0f\u4f1a\u793eWESEEK\u306b\u3064\u3044\u3066<\/h2>\n<p><a href=\"https:\/\/weseek.co.jp\/?utm_source=connpass-top&amp;utm_medium=web-site&amp;utm_campaign=connpass-top-weseek\">\u682a\u5f0f\u4f1a\u793eWESEEK<\/a>\u306f\u3001\u30b7\u30b9\u30c6\u30e0\u958b\u767a\u306e\u30d7\u30ed\u30d5\u30a7\u30c3\u30b7\u30e7\u30ca\u30eb\u96c6\u56e3\u3067\u3059\u3002<\/p>\n<p>\u3010\u73fe\u5728\u306e\u4e3b\u306a\u4e8b\u696d\u3011<\/p>\n<ol>\n<li>\u901a\u4fe1\u5927\u624b\u4f01\u696d\u306e\u696d\u52d9\u30d5\u30ed\u30fc\u81ea\u52d5\u5316\u30d7\u30ed\u30b8\u30a7\u30af\u30c8<\/li>\n<li>\u30bd\u30fc\u30b7\u30e3\u30eb\u30b2\u30fc\u30e0\u306e\u53d7\u8a17\u958b\u767a<\/li>\n<li>\u81ea\u793e\u767a\u30aa\u30fc\u30d7\u30f3\u30bd\u30fc\u30b9\u30d7\u30ed\u30c0\u30af\u30c8\u300c<a href=\"https:\/\/growi.org\/ja\/?utm_source=connpass-top&amp;utm_medium=web-site&amp;utm_campaign=connpass-top-growi\"><strong>GROWI<\/strong><\/a>\u300d\u300c<strong><a href=\"https:\/\/growi.cloud\/?utm_source=connpass-top&amp;utm_medium=web-site&amp;utm_campaign=connpass-top-growi-cloud\">GROWI.cloud<\/a><\/strong>\u300d\u306e\u958b\u767a<\/li>\n<\/ol>\n<h3>GROWI<\/h3>\n<p><a href=\"https:\/\/growi.org\/ja\/?utm_source=connpass-top&amp;utm_medium=web-site&amp;utm_campaign=connpass-top-growi\"><strong>GROWI<\/strong><\/a>\u306f\u3001Markdown\u8a18\u6cd5\u3067\u30da\u30fc\u30b8\u3092\u8a18\u8ff0\u3067\u304d\u308b\u30aa\u30fc\u30d7\u30f3\u30bd\u30fc\u30b9\u306eWiki\u30b7\u30b9\u30c6\u30e0\u3067\u3059\u3002<\/p>\n<h3>GROWI.cloud<\/h3>\n<p><a href=\"https:\/\/growi.cloud\/?utm_source=connpass-top&amp;utm_medium=web-site&amp;utm_campaign=connpass-top-growi-cloud\"><strong>GROWI.cloud<\/strong><\/a>\u306fOSS\u306eGROWI\u3092\u5c02\u9580\u7684\u77e5\u8b58\u304c\u306a\u304f\u3066\u3082\u7c21\u5358\u306b\u904b\u7528\u30fb\u7ba1\u7406\u3067\u304d\u308b\u3001\u6cd5\u4eba\u30fb\u500b\u4eba\u5411\u3051\u306e\u5546\u7528\u30b5\u30fc\u30d3\u30b9\u3067\u3059\u3002<\/p>\n<p>\u5927\u624bSIer\u30fbISP\u3084\u4e2d\u5c0f\u4f01\u696d\u3001\u5927\u5b66\u306e\u7814\u7a76\u5ba4\u306a\u3069\u69d8\u3005\u306a\u5834\u6240\u3067\u3054\u5229\u7528\u3044\u305f\u3060\u3044\u3066\u304a\u308a\u307e\u3059\u3002<\/p>\n<p>\u3010\u4e3b\u306a\u7279\u5fb4\u3011<\/p>\n<ul>\n<li>\u30c6\u30ad\u30b9\u30c8\u3082\u56f3\u8868\u3082\u3069\u3093\u3069\u3093\u66f8\u3051\u308b\u3001\u5f37\u529b\u306a\u7de8\u96c6\u6a5f\u80fd<\/li>\n<li>\u30c1\u30fc\u30e0\u62e1\u5927\u306b\u8fc5\u901f\u306b\u5bfe\u5fdc\u3067\u304d\u308b\u7ba1\u7406\u8005\u5411\u3051\u6a5f\u80fd\u3092\u63d0\u4f9b<\/li>\n<li>\u5145\u5b9f\u3057\u305f\u6a5f\u80fd\u30fb\u30b5\u30dd\u30fc\u30c8\u3067\u30a8\u30f3\u30bf\u30fc\u30d7\u30e9\u30a4\u30ba\u306b\u3082\u5bfe\u5fdc<\/li>\n<\/ul>\n<p>\u3010\u5c0e\u5165\u4e8b\u4f8b\u8a18\u4e8b\u3011<\/p>\n<p>\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u30de\u30eb\u30c1\u30d5\u30a3\u30fc\u30c9\u682a\u5f0f\u4f1a\u793e\u69d8<br \/>\n[<a href=\"https:\/\/growi.cloud\/interviews\/mfeed\/?utm_source=connpass-top&amp;utm_medium=web-site&amp;utm_campaign=mf:embed:cite\">https:\/\/growi.cloud\/interviews\/mfeed\/?utm_source=connpass-top&utm_medium=web-site&utm_campaign=mf:embed:cite<\/a>]<\/p>\n<p>\u682a\u5f0f\u4f1a\u793eHIKKY\uff08VR\u6cd5\u4ebaHIKKY\uff09\u69d8<br \/>\n[<a href=\"https:\/\/growi.cloud\/interviews\/hikky:embed:cite\">https:\/\/growi.cloud\/interviews\/hikky:embed:cite<\/a>]<\/p>\n<h3>WESEEK Tech Conference<\/h3>\n<p>WESEEK Tech Conference\u306f\u3001\u682a\u5f0f\u4f1a\u793eWESEEK\u304c\u4e3b\u50ac\u3059\u308b\u30a8\u30f3\u30b8\u30cb\u30a2\u5411\u3051\u306e\u52c9\u5f37\u4f1a\u3067\u3059\u3002<br \/>\u6708\u306b2\u56de\u307b\u3069\u3001WESEEK\u306b\u6240\u5c5e\u3059\u308b\u30a8\u30f3\u30b8\u30cb\u30a2\u304c\u69d8\u3005\u306a\u30c6\u30fc\u30de\u3067\u767a\u8868\u3092\u884c\u3046\u4e88\u5b9a\u3067\u3059\u3002<\/p>\n<p>\u6b21\u56de\u306f\u30019\/2(\u6728) 19:00~20:00\u300eReact \u3067\u30d5\u30a9\u30fc\u30e0\u3092\u30b9\u30de\u30fc\u30c8\u306b\u5b9f\u88c5\u3059\u308b\u300f<\/p>\n<p>\u521d\u5fc3\u8005\u306e\u65b9\u5411\u3051\u306b\u3001Form \u306e\u57fa\u790e\u3084React \u3067\u306e\u30d5\u30a9\u30fc\u30e0\u306e\u4f7f\u3044\u65b9\u3001\u305d\u3057\u3066ReactHookForm \u3092\u4f7f\u3063\u305f\u4fbf\u5229\u306a\u30d5\u30a9\u30fc\u30e0\u306e\u4f5c\u308a\u65b9\u3092\u89e3\u8aac\u3057\u307e\u3059\uff01<\/p>\n<p>\u73fe\u5728\u3001connpass\u3084TECH PLAY\u3067\u53c2\u52a0\u53d7\u4ed8\u4e2d\u3067\u3059\u3002\u7686\u69d8\u306e\u3054\u53c2\u52a0\u3092\u304a\u5f85\u3061\u3057\u3066\u304a\u308a\u307e\u3059\uff01<br \/>\n[<a href=\"https:\/\/weseek.connpass.com\/event\/222042\/:embed:cite\">https:\/\/weseek.connpass.com\/event\/222042\/:embed:cite<\/a>]<br \/>\n<a href=\"https:\/\/techplay.jp\/event\/827905\">TECH PLAY\u306f\u3053\u3061\u3089\u304b\u3089<\/a><\/p>\n<h3>\u4e00\u7dd2\u306b\u50cd\u304f\u4ef2\u9593\u3092\u52df\u96c6\u3057\u3066\u3044\u307e\u3059<\/h3>\n<p>\u6771\u4eac\u306e\u9ad8\u7530\u99ac\u5834\u30aa\u30d5\u30a3\u30b9\u3001\u5927\u5206\u306b\u3042\u308b\u5225\u5e9c\u30b5\u30c6\u30e9\u30a4\u30c8\u30aa\u30d5\u30a3\u30b9\u306b\u3066\u30a8\u30f3\u30b8\u30cb\u30a2\u3092\u52df\u96c6\u3057\u3066\u304a\u308a\u307e\u3059\u3002<\/p>\n<p>\u4e2d\u9014\u63a1\u7528\u3060\u3051\u3067\u306f\u306a\u304f\u3001\u30a4\u30f3\u30bf\u30fc\u30f3\u30b7\u30c3\u30d7\u3082\u7a4d\u6975\u7684\u306b\u53d7\u3051\u5165\u308c\u3066\u3044\u307e\u3059\uff01<\/p>\n<p>\u8a73\u3057\u3044\u52df\u96c6\u8981\u9805\u306f\u3001\u5f0a\u793eHP\u306e<a href=\"https:\/\/weseek.co.jp\/recruit.html\">\u63a1\u7528\u30da\u30fc\u30b8<\/a>\u304b\u3089\u3054\u78ba\u8a8d\u304f\u3060\u3055\u3044\u3002<\/p>\n<h4>\u95a2\u9023\u8a18\u4e8b<\/h4>\n<p><a href=\"https:\/\/weseek.co.jp\/tech\/525\/\">\u958b\u767a\u3067\u306e\u30ed\u30c3\u30af\u306e\u91cd\u8981\u6027\u3068ORM\u306e\u30ed\u30c3\u30af\u5b9f\u73fe\u4f8b\u301c\u697d\u89b3\u7684\u30ed\u30c3\u30af\u306e\u5229\u7528\u4f8b|\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af O\/R \u30de\u30c3\u30d1\u30fc<\/a><\/p>\n<p><a href=\"https:\/\/weseek.co.jp\/tech\/137\/\">\u958b\u767a\u3067\u306e\u30ed\u30c3\u30af\u306e\u91cd\u8981\u6027\u3068ORM\u3067\u306e\u30ed\u30c3\u30af\u306e\u5b9f\u73fe\u4f8b |\u697d\u89b3\u7684\u30ed\u30c3\u30af\u306e\u7d39\u4ecb<\/a><\/p>\n<p><a href=\"https:\/\/weseek.co.jp\/tech\/510\/\">Puppeteer\u3067\u5b9a\u671f\u7684\u306b\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3053\u306e\u8a18\u4e8b\u306f\u30012021\/8\/19 \u306b\u884c\u308f\u308c\u305f WESEEK Tech Conference \u306e\u5185\u5bb9\u3092\u307e\u3068\u3081\u305f\u3082\u306e\u3067\u3059\u3002 \u76ee\u6b21 \u306f\u3058\u3081\u306b \u69cb\u6210\u306e\u6982\u8981 \u307e\u305a\u521d\u3081\u306b\u4eca\u56de\u7d39\u4ecb\u3059\u308b\u69cb\u6210\u306e\u6982\u8981\u3092\u8aac\u660e\u3057\u307e\u3059\u3002 \u56f3\u3092\u898b\u3066\u3044\u305f\u3060\u3051\u308c\u3070\u308f\u304b\u308b<\/p>\n","protected":false},"author":3,"featured_media":884,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[51,154,2],"tags":[],"_links":{"self":[{"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/posts\/837"}],"collection":[{"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/comments?post=837"}],"version-history":[{"count":21,"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/posts\/837\/revisions"}],"predecessor-version":[{"id":4041,"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/posts\/837\/revisions\/4041"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/media\/884"}],"wp:attachment":[{"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/media?parent=837"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/categories?post=837"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/weseek.co.jp\/tech\/wp-json\/wp\/v2\/tags?post=837"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}