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

Properly namespace component attachments after installation #85

Open
tsega opened this issue Dec 29, 2021 · 1 comment
Open

Properly namespace component attachments after installation #85

tsega opened this issue Dec 29, 2021 · 1 comment
Labels
🪄 Enhancement New feature or request.

Comments

@tsega
Copy link

tsega commented Dec 29, 2021

Expected Behavior

When installing a component in Emulsify Drupal if the component includes a library to be attached like a JavaScript file, then the attachment should be names-spaced under the theme.

Additionally, the attachment should be defined in THEME_NAME.libraries.yml file if it is not already defined.

Current Behavior

The emulsify namespace is used and causes JavaScript functionality to fail.

Possible Solution

After adding the component, Emulsify CLI should replace emulsify with the specific theme name much like how it does it in .cli/init.js:89.

Steps to Reproduce (for bugs)

  1. Add the tabs component from compound; emulsify component install tabs
  2. Look into the twig file of the newly added component: @components/02-molecules/tabs/tabs.twig
  3. You will see the attached library is name-spaced under emulsify not the actual theme.

Your Environment

  • Version used: 1.5.0
  • Browser Name and version: Google Chrome v96.0.4664.110
  • Operating System and version (desktop or mobile): macOS Big Sur v11.6.1
@ModulesUnraveled ModulesUnraveled added the 🪄 Enhancement New feature or request. label Dec 29, 2021
@ModulesUnraveled
Copy link
Contributor

Oh, dang! Didn't think of that. I've added this to the Emulsify Project board. We'll prioritize it with the other tickets on the first Thursday of the month.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🪄 Enhancement New feature or request.
Projects
No open projects
Status: Backlog
Development

No branches or pull requests

2 participants