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

Why is max word length 22 characters? #3

Open
GEMI opened this issue Apr 7, 2014 · 4 comments
Open

Why is max word length 22 characters? #3

GEMI opened this issue Apr 7, 2014 · 4 comments

Comments

@GEMI
Copy link

GEMI commented Apr 7, 2014

Max word length is 22 chars, this seems slightly low because there are plenty of longer words.

If you get a longer word app crashes. Uncaught RangeError: Invalid array length

@the-happy-hippo
Copy link
Contributor

On their blog Spritz claim average human is only capable of perceiving about 13 letters at a time. I guess they assume longer words should be split... alternatively one might try to prolong time duration for such instances.

@igloro
Copy link

igloro commented Apr 11, 2014

Word should be splitted, but it crashes.

@the-happy-hippo
Copy link
Contributor

I agree, the crash should be fixed.

@igloro
Copy link

igloro commented Apr 14, 2014

My fix - http://pastebin.com/Xqy9CqXA, but it doesn't solves problem fully. The fix check if word Index exists in array and is not undefined. If does, it skips. This way code doesn't crashes at "long word".

the-happy-hippo added a commit to the-happy-hippo/spray that referenced this issue May 7, 2014
Add guard of zero or negative num in String.repeat(num)
so it won't crash on long words.
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

No branches or pull requests

3 participants