Skip to content
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

Add rails 8 support #2167

Merged
merged 23 commits into from
Nov 21, 2024

Conversation

reeganviljoen
Copy link
Collaborator

@reeganviljoen reeganviljoen commented Nov 18, 2024

What are you trying to accomplish?

Add rails 8 appraisal and ci to matrix and move sprockets to be depended on for older versions

@reeganviljoen reeganviljoen changed the title Add rails 8 appraisal Add rails 8 support Nov 18, 2024
@reeganviljoen
Copy link
Collaborator Author

@joelhawksley sorry I only see you also had a pr for this now, I have however fixed the issues that caused your pr to fail, if you don't mind taking a look

Copy link
Contributor

@camertron camertron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @reeganviljoen, thanks for putting this PR together!

Does Rails 8 no longer include sprockets? If not, can we switch to propshaft instead? I think that's what most Rails 8 apps will be using, and it'd be nice to test against the most common configuration.

test/sandbox/config/application.rb Outdated Show resolved Hide resolved
test/sandbox/test/rendering_test.rb Outdated Show resolved Hide resolved
test/sandbox/test/rendering_test.rb Outdated Show resolved Hide resolved
@@ -1,3 +1,3 @@
# frozen_string_literal: true

Rails.application.config.assets.precompile += %w[admin.css]
if Rails.version.to_f <= 7.2 then Rails.application.config.assets.precompile += %w[admin.css] end
Copy link
Contributor

@camertron camertron Nov 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this need to change? EDIT: do we still need admin.css? I don't know what it's used for.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes but propshaft auto includes it

test/sandbox/config/application.rb Outdated Show resolved Hide resolved
@reeganviljoen
Copy link
Collaborator Author

@camertron I have added propshaft at last, it does however come with less features by design, like for instance I can not set a custom host as far as I know so those tests are omitted on new rails versions

@reeganviljoen
Copy link
Collaborator Author

@camertron @Spone @joelhawksley @BlakeWilliams anyone had a chance to review this, it is quite important

docs/CHANGELOG.md Outdated Show resolved Hide resolved
test/sandbox/config/initializers/assets.rb Outdated Show resolved Hide resolved
test/sandbox/test/rendering_test.rb Outdated Show resolved Hide resolved
@joelhawksley joelhawksley enabled auto-merge (squash) November 21, 2024 16:48
@reeganviljoen
Copy link
Collaborator Author

Thanks @joelhawksley for the additions

@joelhawksley joelhawksley merged commit e21b61d into ViewComponent:main Nov 21, 2024
19 checks passed
reeganviljoen added a commit to reeganviljoen/view_component that referenced this pull request Nov 21, 2024
* add rails 8 appraisal

* add rails 8 ci

* fix lint

* updatre gemfile

* fix lint

* fix specs

* fix specx=cs again

* fix specs

* fix specs

* f*** these specs already

* fix lint

* fix benchmarks

* f*** these specs already

* fix lint

* fis spcs

* fix ci

* Update test/sandbox/test/rendering_test.rb

Co-authored-by: Cameron Dutro <[email protected]>

* fix ci

* fix lint

* fix lint

* try fix benchmark ci

* Apply suggestions from code review

* Update test/sandbox/test/rendering_test.rb

---------

Co-authored-by: Cameron Dutro <[email protected]>
Co-authored-by: Joel Hawksley <[email protected]>
reeganviljoen added a commit to reeganviljoen/view_component that referenced this pull request Nov 21, 2024
* add rails 8 appraisal

* add rails 8 ci

* fix lint

* updatre gemfile

* fix lint

* fix specs

* fix specx=cs again

* fix specs

* fix specs

* f*** these specs already

* fix lint

* fix benchmarks

* f*** these specs already

* fix lint

* fis spcs

* fix ci

* Update test/sandbox/test/rendering_test.rb

Co-authored-by: Cameron Dutro <[email protected]>

* fix ci

* fix lint

* fix lint

* try fix benchmark ci

* Apply suggestions from code review

* Update test/sandbox/test/rendering_test.rb

---------

Co-authored-by: Cameron Dutro <[email protected]>
Co-authored-by: Joel Hawksley <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants