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

New attribute-tools extension based on class-tools #70

Closed
wants to merge 1 commit into from

Conversation

jamcole
Copy link

@jamcole jamcole commented Aug 1, 2024

This is a new extension that provides similar functionality as class-tools, but for arbitrary attributes.

I use picoCSS and it uses attributes for various display functionality instead of just classes.

The operations are "set" and "remove" (add and toggle from class-tools weren't necessary):

  • set
    • attribute_name
    • attribute_name=attribute_value
  • remove
    • attribute_name

The code-base is a copy of class-tools and update for the new functionality, so hopefully I followed all the project conventions.

Copy link

netlify bot commented Aug 1, 2024

Deploy Preview for htmx-extensions ready!

Name Link
🔨 Latest commit 50e1d50
🔍 Latest deploy log https://app.netlify.com/sites/htmx-extensions/deploys/66aaebe4bad02600087fffc2
😎 Deploy Preview https://deploy-preview-70--htmx-extensions.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.

@Telroshan
Copy link
Collaborator

Hey, I would suggest publishing your own extension repo for now and list it in this repo's community extensions.
Adding an extension to the repo itself makes it kind of an "official" extension that we'd have to provide long-term support for, I hope you'll understand we can't do that with all extensions!
All extensions in this repo were already there in 1.0, and with htmx 2 we wanted to take a different approach, to let community easily register their extensions in our extensions list while we let them handle their support.

We can always discuss later if an extension should or should not make it into the core, but I would suggest making it a community extension first.

I know this can feel frustrating, apologies for that! We'll have to define contributing guidelines at some point for this repo, we're still playing it by ear for now

Note: yes, this is a shameless copy-paste from my comments in #44 and #60, but it applies just as well!

@Telroshan Telroshan closed this Aug 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants