henry-sarabia / blank Goto Github PK
View Code? Open in Web Editor NEWDetect blank strings or remove whitespace from strings
License: MIT License
Detect blank strings or remove whitespace from strings
License: MIT License
As of now, to check multiple strings for blanks the user needs to create their own for loop. Implement a function to check an entire slice of strings for blanks to solve this issue.
After some research, it seems the regexp package might not be the best fit for identifying whitespace. Although it does catch some control characters, there are others that are not caught by the regular expression.
The escaped vertical tab character '\v' is whitespace but is not currently identified as such.
The unicode non-breaking space character U+00A0 is also not identified as whitespace.
There are definitely other similar cases. To solve this issue, it may be prudent to replace the regular expression with a more naive but thorough individual rune iteration and inspection.
I am relatively content with the package name, but still believe it doesn't quite convey its purpose. It maybe prudent to explore changing it to blank
and subsequently changing the public functions as follows:
The thought is that it may increase the ergonomics in regards to using the package.
There is no README for this package yet. Add a README file with information on what the package is used for, how to use it and how to contribute. Also add build status, test coverage, and Go report card score.
This package is not integrated with Travis CI and Coveralls yet so its build and test coverage are unknown to other GitHub users. Add a .travis.yml file and activate coverage.
Adopting semantic versioning using git tags will allow users to differentiate versions of the package and, more importantly, identify when the package has made a breaking change.
RemoveSpace
is a descriptive function name but redundant to a user. A user will type blank.RemoveSpace
.
This can be simplified to blank.Remove
for less visual noise, less typing, a clear and concise name, and congruence with the other function names (blank.Is
and blank.Has
).
The current README explains the function of the package but the explanation is unwieldy. It should be rewritten for clarity and conciseness.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.