-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Breaking change] Chanko no longer modifies view_paths to add or remove its own view path. #78
[Breaking change] Chanko no longer modifies view_paths to add or remove its own view path. #78
Conversation
9a6836a
to
24df553
Compare
24df553
to
1ffcd1e
Compare
README.md
Outdated
end | ||
end | ||
``` | ||
In its previous version, Chanko added the views path of the unit to Rails' view file search. However, it no longer does that. If you still want to place the views path under the unit, please create a symbolic link under app/views/units and refer to it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
大きな変更だから、メジャーバージョンをあげるほうが良さそうですね。今が2だから3かな。
previous versionというより、3より前のバージョンにするのが良いかなと。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
たしかにそのように書いたほうが分かりやすいですね。変更をします。バージョンの方針も相違ありません。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In version 2 and earlier, Chanko extended Rails' search path to include the views path of the unit. This functionality has been discontinued. To maintain the views path under the unit, you will need to manually create a symbolic link in app/views/units to access it.
としました。このコードをマージ後にREADMEの修正など、version3への準備を行います。
cookpad#78 - Adds support for Rails 7 - Drops support for eol versions of Ruby and Rails.
cookpad#78 - Adds support for Rails 7 - Drops support for eol versions of Ruby and Rails.
Rails 7.1で、viewの探索対象を管理するPathSet#pathsがfreezeされました。この変更でChankoの利用可能viewを動的に管理する仕組みが動かなくなります。
この仕組みはUnitのviewを外から不用意に利用する事を避けるためでしたが、無理をして維持する価値はおそらくないため、今回を機に関連コードと機能を削除します。
今後、Chankoはviewsに関して何の仕組みも持ちません。代替する管理方法の一例として、他のassetsと同様にapp/views/の下にシンボリックリンクを作成する方法をREADMEに追加しました。
Before
After