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

Update deps + rename options for clarity #22

Closed
wants to merge 2 commits into from

Conversation

HoldYourWaffle
Copy link
Contributor

I updated the dependencies (again) since, among others, the main reshape module was updated.

I also renamed the defaultTag and skipTags options to replacementTag and additionalTags respectively. I feel like those names convey the actually meaning of these options better.

There are some features I need for my use case that I'm going to try and add myself. I will of course create PR's for those (although you shouldn't feel obligated to merge them), but since these (mini) changes could create (big) conflicts I'd love to hear if you're actually approving them before I continue.

@HoldYourWaffle
Copy link
Contributor Author

HoldYourWaffle commented May 17, 2019

Whoops I forgot that this is obviously a breaking change. Perhaps it wasn't the best idea to do this kind of stuff at 1 AM....

There are 3 solutions to this:

  • Drop the PR
  • Fall back to the old options
  • Release a new major version

I created a new commit that adds the fallback behavior (including a test) as I feel like that's the best option, but it's up to you.

HoldYourWaffle added a commit to HoldYourWaffle2/reshape-custom-elements that referenced this pull request May 17, 2019
This may not seem like a useful feature at first (since we're typing both the class an tag name again), but in my opinion it helps convey *semantic* meaning rather than *syntactical* meaning when editing templates.

Possible improvement points:
- Not sure how I'm supposed to handle multiple attribute values here
- pretty-quick is being a bit weird, are you sure this is how you want it to be formatted?
- Maybe a different default attribute name?
- Maybe a shorter option name?
- The replacementTag option (reshape#22) should probably be renamed to defaultReplacementTag
@jescalan
Copy link
Member

Could we split this into two pull requests? One to update deps, and one to rename the options - that would make more sense for me 😁

@HoldYourWaffle
Copy link
Contributor Author

I could, but the option renaming is included (and superseded) in #23, so creating another PR for that wouldn't make sense.
I'll just revert the changes that are not dependency related.

@HoldYourWaffle
Copy link
Contributor Author

Hold on the dependency stuff is also included in #23, so that wouldn't make sense either.
Shall I just close this so we can decide everything there?

@jescalan
Copy link
Member

Yep!

@HoldYourWaffle
Copy link
Contributor Author

Did it, and also posted an (admittedly pretty long) response in #23.

@HoldYourWaffle HoldYourWaffle deleted the clarity branch May 17, 2019 20:10
HoldYourWaffle added a commit to HoldYourWaffle2/reshape-custom-elements that referenced this pull request May 31, 2019
This may not seem like a useful feature at first (since we're typing both the class an tag name again), but in my opinion it helps convey *semantic* meaning rather than *syntactical* meaning when editing templates.

Possible improvement points:
- Not sure how I'm supposed to handle multiple attribute values here
- pretty-quick is being a bit weird, are you sure this is how you want it to be formatted?
- Maybe a different default attribute name?
- Maybe a shorter option name?
- The replacementTag option (reshape#22) should probably be renamed to defaultReplacementTag
jescalan pushed a commit that referenced this pull request Jun 3, 2019
* Update deps + rename options for clarity

* Add typescript definitions

reshapeCustomElements(..) returns a plain 'Function' for now since the core reshape module doesn't include definitions yet

* Make it possible to locally override the default replacement tag

This may not seem like a useful feature at first (since we're typing both the class an tag name again), but in my opinion it helps convey *semantic* meaning rather than *syntactical* meaning when editing templates.

Possible improvement points:
- Not sure how I'm supposed to handle multiple attribute values here
- pretty-quick is being a bit weird, are you sure this is how you want it to be formatted?
- Maybe a different default attribute name?
- Maybe a shorter option name?
- The replacementTag option (#22) should probably be renamed to defaultReplacementTag

* Custom tag ↔ replacement tag map option

The README could probably be worded better

* Move the HTML in the README to it's own (syntax highlighted) section

* Add a generic blacklist

* Change the replacementTagMap to a more convenient format

* Make sure option names are consistent and update TS definitions

* Infer additionalTags from replacementTagMap
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.

None yet

2 participants