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

remove white spaces from unit names #56

Merged
merged 3 commits into from
Oct 23, 2019
Merged

remove white spaces from unit names #56

merged 3 commits into from
Oct 23, 2019

Conversation

geraldo
Copy link
Contributor

@geraldo geraldo commented Oct 23, 2019

Removing white spaces makes it possible to use unit names. This makes it possible to use property "name" in topojson files instead of "fips" as discussed in issue #55.

Copy link
Owner

@yaph yaph left a comment

Choose a reason for hiding this comment

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

Thanks for looking into this! I think it's a little safer to replace whitespace with an underscore replace(/ /g, '_') to reduce the potential for name collisions. I know that just removing whitespace in identifiers has bitten me in the past. Do you have thoughts on this?

@geraldo
Copy link
Contributor Author

geraldo commented Oct 23, 2019

Indeed using an underscore is more safe, rerolled the pull request.

@yaph
Copy link
Owner

yaph commented Oct 23, 2019

Sorry, I should have kept the \s instead of the literal space character, can you update the PR again.

@yaph yaph merged commit 1ede0e3 into yaph:master Oct 23, 2019
@yaph
Copy link
Owner

yaph commented Oct 23, 2019

Thanks for your contribution Gerald!

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.

2 participants