Saki
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights
    • Engagement control
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Versions and GitHub Sync Note Insights Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       owned this note    owned this note      
    Published Linked with GitHub
    Subscribed
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    Subscribe
    # 【第10週】パRails輪読会 \(2022\-09\-26\~ 2022\-09\-30\) ###### tags: `パRails(2回目)` - [開催概要](https://hackmd.io/rOcLR0riRqmOgEF0_Ssm0A?both) - [パRails輪読会 ノートまとめ](https://hackmd.io/5emISRvRRXapmakSiHnFJg?both) ## パRailsのサンプルコード・正誤表 - [サポートページ:パーフェクトRuby on Rails【増補改訂版】:|技術評論社](https://gihyo.jp/book/2020/978-4-297-11462-6/support) - [パRails 環境構築の手順](https://hackmd.io/y7qb2BRMT2Wd4tAtKYObcQ) ## 目次 [TOC] ------ ## 2022\-09\-26(月) ### 連絡事項や確認・相談 ### タイムキーパー - Saki ### ドライバー - tomonariさん ### 読んだところ - P.268 [5-6-2途中 サーバーサイドを実装する]〜 ### 次回 - P.274 [5-6-5 Action Cableのワーカ数を設定する] ### 自由に使う共有スペース ### 各自の疑問点や気づき、学んだこと - @fuwa - `Acton Cable` は`WebSocket通信` によるリアルタイム更新機能を実装できるフレームワーク - そもそも`Action Cable` ってなんだっけという感じだったので復習した方が良いかも - リアルタイムで何かが動くのを見るのは楽しいですね〜 - LEF - Chat roomで入力した文章が、リロードなしに他の画面でも反映されて凄いと思いました! - Web用のサーバーとWebSocket用のサーバーを分けると、具体的にどのような点で便利なのかよく分からなかったので、自分でも調べようと思います。 - @Saki - チャット機能の仕組みやAction Cable自体触るのも初めてなので難しかった! - Websocket - [WebsocketとRedis Pub/Sub \- Qiita](https://qiita.com/rihofujino/items/7bf4b99e2176f63ca7ef) - 双方向通信を実現するには、いつものHTTPリクエストとかの仕組みとは違う技術を使っているらしい - Websocketの接続管理を行うアダプタというものがあって、これはデフォルトの設定だと環境によって使うアダプタが違う。 - インメモリ:ソフトウェアを実行する際、使用するプログラムやデータのすべてをメインメモリ(RAM)上に読み込み、ストレージ(外部記憶装置)を使わないこと - 開発環境はasync。これはインメモリ。 - @tomonari - チャットアプリ動かせて面白かったです! - puma動かした時に`ERROR: No application configured, nothing to run`が出たのが気になります。 - command + F でコード内検索できる! - @haruguchi - Action Cable使ったことないし途中だったから局所的な部分しかわからないや - `WebSocket`ってなんでしたっけ? - 誰か自作サービスでAction Cable使おうとしてた人がいたような:thinking_face: ### 本日の振り返り(よかった点・次回に向けての改善点・今の気分などなんでもOK) - @garammasala29 - 卒業してからやる気が出なくて温泉に浸かってぼけーっと過ごしていました - :urayama: - :onnseniina-: - これからちゃんと輪読会参加していくので復習しておきます!!! - わいわい!! - @haruguchi - 元気ですか?僕は元気です! - 💯 - LEF - ガラムマサラさんご卒業おめでとうございます!🎉 - 以前質問し忘れてしまったのですが、Sakiさんがターミナル補完のツールで何を使っているか気になります!🖥 - @fuwa - ガラムマサラさんご卒業おめでとうございます〜!! - 今日は秋葉原とお茶の水をぶらぶらしていました - 初めてチーム開発でページをまるっと作るissueが渡されたのでやや途方に暮れています - @tomonari - ガラムマサラさんご卒業なのですね!おめでとうございます! - LEFさん復帰嬉しいです - haruguchiさんGoogleカレンダー教えてください:pray: - おお!いいですよ!いつがいいですか? - @Saki - LEFさん&ガラムマサラさん、お久しぶりです〜! - 正規化むずかしい ------ ## 2022\-09\-27(火) ### 連絡事項や確認・相談 ### タイムキーパー - Saki ### ドライバー - ガラムマサラさん ### 読んだところ - P.274 [5-6-5 Action Cableのワーカ数を設定する]〜 ### 次回 - P.279 [6-1-2 ルーティングの仕様] ### 自由に使う共有スペース ### 各自の疑問点や気づき、学んだこと - @garammasala29 - Action Cableもテストができる。便利そうなヘルパーメソッドを活用している - チャネル、コネクション、ブロードキャスト…復習が必要 - テストを書いているとどんな実装したかなんとなく理解できたのでよかった。TDDも大事 - LEF - assert_broadcast_onの部分と、「performメソッドでクライアントからspeakメソッドを呼び出すようにテストして……」のところの理解が曖昧なので、後で調べようと思います。 - [ActionCable::TestHelper](https://api.rubyonrails.org/v6.0.2.2/classes/ActionCable/TestHelper.html) - [assert_broadcast_on | Railsドキュメント](https://railsdoc.com/page/assert_broadcast_on) - RSpecだとテストコードをどのように書くのかについても、学習していきたいです。 - @Saki - チャネルのテスト - `subscribed`メソッド内の`stream_from`によって、指定した名前のブロードキャストをサブスクライブする - テストでは、`subscribe`を実行した時に、指定した名前と同じかどうか検証しているぽい - コネクションのテスト:cookieのユーザー情報と作成したコネクションの認証ユーザー情報が同じかどうかテストする - ワーカスレッド / サブスクライブ/ チャネル / コネクション / WebSocket など分からない横文字が多かった... - @tomonari - ストリームとかワーカスレッドのような基礎情報っぽいものの理解もしていきたいと思いました。 - BootCampのミートアップイベントの募集は何を使ってるんだろう?ConnpassとDoorkeeperは使ってないみたいだけど:thinking_face: - @fuwa - 重い処理の場合、ワーカスレッドが少ないと応答時間が長くなってしまうらしい - なんかAction Cable周り全体的にふわっとした理解なので復習が必要な気がします〜 - ### 本日の振り返り(よかった点・次回に向けての改善点・今の気分などなんでもOK) - @maimu_x2x - 昨日休んでしまったため、今日の部分と合わせて復習します! - パRailsも半分超えましたね〜✨ - @garammasala29 - 6章たのしみ! - 今日も膝にヒアルロン酸入れてきました - LEF - FBC内でもくもく会が始まるそうなので、進捗が捗らないときに参加したいな~と思いました。https://discord.com/channels/715806612824260640/842169720237195304/1024248830507626536 - ピノキオを20年ぶりくらいに見ました。🎥 - @tomonari - そういえば明後日ミートアップですね。参加するつもりなので同じテーブルになったらよろしくお願いします! - @Saki - パRails難しくて全然オーガナイズできてなくてすみません💦皆さんいつもきてくださってありがとうございます🙏 - @fuwa - チーム開発でVue.jsをやることになったのですが、Vue.jsなんもわからんとなったので復習せねば - 筋トレ終わりに大判焼き食べたらおいしかったです ------ ## 2022\-09\-28(水) ### 連絡事項や確認・相談 ### タイムキーパー - Saki ### ドライバー - fuwaさん ### 読んだところ - P.279 [6-1-2 ルーティングの仕様]〜 ### 次回 - P.288 [6-3 OAuthを利用して「GitHubでログイン」機能を作る] ### 自由に使う共有スペース ### 各自の疑問点や気づき、学んだこと - @maimu_x2x - hamlを一度も書いたことがないため、まずは読めるようになりたい。 - https://morizyun.github.io/ruby/library-template-engine-haml.html - hamlのインストール方法は本に書いてあるやり方じゃなくてもよさそうなため、調べてみる - => はハッシュロケットと読む - @cafedomancer - ER 図の矢印が何を表現しているのか分からなかった - haml より hamlit のほうがはやい :rocket: - @fuwa - 人生初hamlでした - 自作サービスを作ることになったらhamlにするかslimにするかその他にするか悩ましいです - @tomonari - html2hamlの変換機能だけ使ったらGemを削除する使い方が面白いと思いました。hamlitとこれで使われるGemのhamlが重なってしまうんですね。 - @garammasala29 - テンプレートエンジンの処理速度、hamlはHamlit、erbはErubiが高速な実装 - [Erubi とは何か \- Qiita](https://qiita.com/scivola/items/f0a66fd310b252d04d4b) - `=>`はハッシュロケットでした。ヘビーアローやファットアローと読むのは初耳 - hamlで書いたことがこれまでなかったので、一緒に学習できそうで嬉しい - LEF - hamlやslim、Bootstrap便利そうなので使えるようになりたいです。erbは書くのがちょっとつらいです🥲 - Rails のプラクティスで使ってもよいですよ https://bootcamp.fjord.jp/questions/1326 - そうなんですね!ありがとうございます🙏 - 一発でコメントアウトできないの面倒ですよね🥲 - Saki - `haml-rails`はオリジナル。`hamlit-rails`はこれを速度を速くしたもの - `html2haml`は`haml`に依存、`hamlit-rails`は`hamlit`に依存しているので、hamlを処理するテンプレートエンジンがhamlを処理するテンプレートエンジンは`haml`と`hamlit`の2つになってしまう。2つあると意図しない挙動になってしまうかもなので、html2hamlは変換に使ったらすぐ消す - Rails5あたりから、`ERubi`がデフォルトで入ってるらしい - slim使ってますがちょっとERBに戻りたいです... ### 本日の振り返り(よかった点・次回に向けての改善点・今の気分などなんでもOK) - @maimu_x2x - 2ヶ月ぶりに会社行ったら出社組に驚かれましたw - 今月で辞めてしまう元上司や同僚と色々話してきました - 後輩がTebikiさんに転職していてびっくり👀 - @fuwa - 今日は朝からコメダでモーニングをしつつ学習していました。なんかオシャレな気分になりました。 - チーム開発でVue.js周りをやっていますが、なんとかデータを引っ張ってこれました〜 - LEF - カフェインレスコーヒーを買って飲みました☕ - @cafedomancer - 友達に台湾のルーローハンをもらって食べました。しあわせ :pig: - ルーローハン大好きです✨ - ![](https://i.imgur.com/YCNfB47.png) - @garammasala29 - 梅本さん、いろいろ教えていただいてありがとうございます!!! ------ ## 2022\-09\-29(木) 主催者都合で申し訳ないのですが、お休みにさせてください ----- ## 2022\-09\-30(金) 主催者都合で申し訳ないのですが、お休みにさせてください -----

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully