Skip to content
This repository was archived by the owner on Sep 6, 2018. It is now read-only.

Add colgroup to customizations #14

Open
cacay wants to merge 1 commit intoevancz:masterfrom
cacay:master
Open

Add colgroup to customizations #14
cacay wants to merge 1 commit intoevancz:masterfrom
cacay:master

Conversation

@cacay
Copy link

@cacay cacay commented Dec 16, 2016

colgroup is useful for setting properties of whole columns (like width) easily. This would also address #12 (in fact, this is exactly the use case I have). Also, it is also part of HTML so we should include it.

@ericgj ericgj mentioned this pull request Apr 18, 2017
@ChristophP
Copy link

@cacay Sweet, I need exactly this as well. I was just about to do it myself, when I found this PR. @evancz any chance of you merging this? Would be much appreciated.

identity

Just { attributes, children } ->
(::) <| Html.caption attributes children
Copy link

@ChristophP ChristophP May 1, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this could be simplified with Maybe.withDefault. Like

caption = Maybe.map (\{ attributes, children } -> (::) <| Html.caption attributes children) customizations.caption |> Maybe.withDefault identity

Not sure if its actually simpler but it would allow for more reuse if you broke some stuff up into smaller functions.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's harder to read your way. What I have takes more lines, but is easier to follow.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, true. Might have been a microoptmization suggestion by me anyway :-).

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Has Evan ever replied to your PR?

@ericgj ericgj mentioned this pull request Aug 31, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants