Skip to content

Feral Cat - Software Development

Building, just because…

  • Python
  • Android
  • Javascript
  • BASH/Terminal
  • Contact
  • Forums

Node

How to Generate a Random Integer in JavaScript (Math.random)

April 6, 2026October 1, 2019 by Carlos
Post about Javascript

The solution for those of you who want me to cut the crap and need to calculate a random integer from 0 to n in Javascript. My Setup macOS Node v12.10.0 The Problem I was writing a React-Native game where I had multiple cards that would be presented to the player. To spice up the … Read more

Categories Javascript Tags Javascript, Node, random, react-native Leave a comment

How to Parse a JSON String Array in JavaScript (JSON.parse)

April 6, 2026October 1, 2019 by Carlos
Post about Javascript

I recently encountered a scenario where I needed to store an array of objects locally for later retrieval. The challenge was converting this array of objects into a string before saving it and then cast a string array of JSON objects to JSON. This led me to figure out how to cast a string array … Read more

Categories Javascript Tags Javascript, JS, Node Leave a comment
© 2026 Feral Cat - Software Development • Built with GeneratePress
Go to mobile version