Closed karth295 closed 7 years ago
Great catch. Let's remove the assertion for now. It can just return {key: '/*'}
. I agree in the future it should do option 2! I've been wanting that too.
I'm not sure what regexp language to use, though. Maybe we should define our own. I like using *
for "anything" rather than "any number of the previous items" like most regexp langs. They make you use .*
for "anything", which is too many characters for the most frequently used feature of the language.
Statebus: 4.0.30 Example repro:
fetch('/*')
Server crashes with this error:
I see that you have a TODO comment there. However, it seems like a security risk to let users easily crash the server (I accidentally did this to tawk the other day). A couple of temporary solution ideas:
[{key: '/state1'}, {key: '/state2'}]
.