fresh icon indicating copy to clipboard operation
fresh copied to clipboard

`fresh routes add <pattern>`

Open lucacasonato opened this issue 2 years ago • 2 comments

A subcommand to create a new route file at the given pattern. Automatically runs fresh manifest after creating the new route.

lucacasonato avatar Mar 07 '22 23:03 lucacasonato

How should this behave with a complex pattern that isnt FS friendly? or more specifically, what path would it create for such a pattern to then use the override?

How about fresh routes add <pattern> [path], and it will error in case of a non-fs friendly pattern with a message saying that path needs to be specified?

crowlKats avatar Mar 09 '22 18:03 crowlKats

I was imagining this <pattern> here is just the file path name (so users/[id] for example. For advanced patterns, we can add a --custom-pattern flag or something.

lucacasonato avatar Mar 13 '22 21:03 lucacasonato

No CLI, so isn't needed anymore.

lucacasonato avatar Aug 26 '22 09:08 lucacasonato