Skip to content

Fix trim option for empty tags#643

Open
AHarman wants to merge 1 commit into
Leonidas-from-XIV:masterfrom
AHarman:fix-trim-for-empty-tags
Open

Fix trim option for empty tags#643
AHarman wants to merge 1 commit into
Leonidas-from-XIV:masterfrom
AHarman:fix-trim-for-empty-tags

Conversation

@AHarman

@AHarman AHarman commented Apr 18, 2022

Copy link
Copy Markdown

Previously, this test would fail:

'test trimming on empty tag with whitespace': skeleton(trim: true, (r) ->
    equ r.sample.emptytestanother[0], '')

where "emptytestanother" looked like this:

    <emptytestanother>

    </emptytestanother>

The value was coming back as \n \n (the whitespace between the tags).

@Leonidas-from-XIV

Copy link
Copy Markdown
Owner

Can you add the test and implement the fix in the CoffeeScript source code?

@AHarman AHarman force-pushed the fix-trim-for-empty-tags branch from 16fd1c7 to 3344f16 Compare April 19, 2022 18:40
@AHarman

AHarman commented Apr 19, 2022

Copy link
Copy Markdown
Author

Sorry about that! Committed the wrong files.

I've fixed that and pushed the right changes.

@a2937

a2937 commented Sep 19, 2024

Copy link
Copy Markdown

This doesn't actually pass the tests for the record.

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.

3 participants