Skip to content

Commit

Permalink
release v3.0.0 (#1711)
Browse files Browse the repository at this point in the history
[Closes #1629]
  • Loading branch information
joelhawksley authored Apr 24, 2023
1 parent e4927ec commit c696930
Show file tree
Hide file tree
Showing 5 changed files with 76 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
view_component (3.0.0.rc6)
view_component (3.0.0)
activesupport (>= 5.2.0, < 8.0)
concurrent-ruby (~> 1.0)
method_source (~> 1.0)
Expand Down
76 changes: 72 additions & 4 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,81 @@ nav_order: 5

## main

* Add Topkey to list of companies using ViewComponent.
### v3.0.0

*Bryan Beshore*
1,000+ days and 100+ releases later, the 200+ contributors to ViewComponent are proud to ship v3.0.0!

We're so grateful for all the work of community members to get us to this release. Whether it’s filing bug reports, designing APIs in long-winded discussion threads, or writing code itself, ViewComponent is built by the community, for the community. We couldn’t be more proud of what we’re building together :heart:

This release makes the following breaking changes, many of which have long been deprecated:

* BREAKING: Remove deprecated slots setter methods. Use `with_SLOT_NAME` instead.

*Joel Hawksley*

* BREAKING: Remove deprecated SlotsV1 in favor of current SlotsV2.

*Joel Hawksley*

* BREAKING: Remove deprecated `content_areas` feature. Use Slots instead.

*Joel Hawksley*

* BREAKING: Remove deprecated support for loading ViewComponent engine manually. Make sure `require "view_component/engine"` is removed from `Gemfile`.

*Joel Hawksley*

* BREAKING: Remove deprecated `generate_*` methods. Use `generate.*` instead.

*Joel Hawksley*

* BREAKING: Remove deprecated `with_variant` method.

* Add OBLSK & PLT4M to list of companies using ViewComponent.
*Joel Hawksley*

* BREAKING: Remove deprecated `rendered_component` in favor of `rendered_content`.

*Joel Hawksley*

* BREAKING: Remove deprecated `config.preview_path` in favor of `config.preview_paths`.

*Joel Hawksley*

*Mike Munroe*
* BREAKING: Support Ruby 2.7+ instead of 2.4+

*Joel Hawksley*

* BREAKING: Remove deprecated `before_render_check`.

*Joel Hawksley*

* BREAKING: Change counter variable to start iterating from `0` instead of `1`.

*Frank S*

* BREAKING: `#SLOT_NAME` getter no longer accepts arguments. This change was missed as part of the earlier deprecation in `3.0.0.rc1`.

*Joel Hawksley*

* BREAKING: Raise `TranslateCalledBeforeRenderError`, `ControllerCalledBeforeRenderError`, or `HelpersCalledBeforeRenderError` instead of `ViewContextCalledBeforeRenderError`.

*Joel Hawksley*

* BREAKING: Raise `SlotPredicateNameError`, `RedefinedSlotError`, `ReservedSingularSlotNameError`, `ContentSlotNameError`, `InvalidSlotDefinitionError`, `ReservedPluralSlotNameError`, `ContentAlreadySetForPolymorphicSlotErrror`, `SystemTestControllerOnlyAllowedInTestError`, `SystemTestControllerNefariousPathError`, `NoMatchingTemplatesForPreviewError`, `MultipleMatchingTemplatesForPreviewError`, `DuplicateContentError`, `EmptyOrInvalidInitializerError`, `MissingCollectionArgumentError`, `ReservedParameterError`, `InvalidCollectionArgumentError`, `MultipleInlineTemplatesError`, `MissingPreviewTemplateError`, `DuplicateSlotContentError` or `NilWithContentError` instead of generic error classes.

*Joel Hawksley*

* BREAKING: Rename `SlotV2` to `Slot` and `SlotableV2` to `Slotable`.

*Joel Hawksley*

* BREAKING: Incorporate `PolymorphicSlots` into `Slotable`. To migrate, remove any references to `PolymorphicSlots` as they are no longer necessary.

*Joel Hawksley*

* BREAKING: Rename private TestHelpers#controller, #build_controller, #request, and #preview_class to avoid conflicts. Note: While these methods were undocumented and marked as private, they were accessible in tests. As such, we're considering this to be a breaking change.

*Joel Hawksley*

### v3.0.0.rc6

Expand Down
2 changes: 1 addition & 1 deletion docs/_data/library.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version: 3.0.0.rc6
version: 3.0.0
2 changes: 1 addition & 1 deletion lib/view_component/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module VERSION
MAJOR = 3
MINOR = 0
PATCH = 0
PRE = "rc6"
PRE = nil

STRING = [MAJOR, MINOR, PATCH, PRE].compact.join(".")
end
Expand Down
3 changes: 1 addition & 2 deletions test/sandbox/test/rendering_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -348,14 +348,13 @@ def test_that_it_has_a_version_number
assert_kind_of Integer, ::ViewComponent::VERSION::MINOR
refute_nil ::ViewComponent::VERSION::PATCH
assert_kind_of Integer, ::ViewComponent::VERSION::PATCH
refute_nil ::ViewComponent::VERSION::PRE

version_string = [
::ViewComponent::VERSION::MAJOR,
::ViewComponent::VERSION::MINOR,
::ViewComponent::VERSION::PATCH,
::ViewComponent::VERSION::PRE
].join(".")
].compact.join(".")
assert_equal version_string, ::ViewComponent::VERSION::STRING
end

Expand Down

0 comments on commit c696930

Please sign in to comment.