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

Isolate and namespace StimulusReflex::Installer #699

Merged
merged 2 commits into from
May 6, 2024
Merged

Conversation

marcoroth
Copy link
Member

@marcoroth marcoroth commented May 2, 2024

Type of PR

Enhancement

Description

This pull request isolates the methods defined lib/stimulus_reflex/installer.rb into a StimulusReflex::Installer constant so they don't pollute the global namespace if the file is required.

CableReady got a similar PR: stimulusreflex/cable_ready#295

Why should this be added

Exposing all the methods from the installer in the global namespace could lead to issues down the road. Methods like options are likely to be overridden.

Checklist

  • My code follows the style guidelines of this project
  • Checks (StandardRB & Prettier-Standard) are passing

Copy link

netlify bot commented May 2, 2024

Deploy Preview for stimulusreflex ready!

Name Link
🔨 Latest commit 388934c
🔍 Latest deploy log https://app.netlify.com/sites/stimulusreflex/deploys/6633fa5d7b0731000825d7cd
😎 Deploy Preview https://deploy-preview-699--stimulusreflex.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@marcoroth marcoroth merged commit e2451ee into main May 6, 2024
18 checks passed
@marcoroth marcoroth deleted the isolate-installer branch May 6, 2024 21:27
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.

1 participant