DEV Community

Luke O'Connell
Luke O'Connell

Posted on

Today I learned- Dynamic Path Segments

Today I learned about dynamic path segments and used them to improve my dice rolling app. I used these dynamic path segments to support all possible combinations of dice rolls. When we start a path segment with a colon it becomes a dynamic path segment. I also learned how to use the params hash to receive user input. I was able to refactor the code after using the dynamic path segments to make it shorter while still being functional.

Top comments (0)