csells / go_router

The purpose of the go_router for Flutter is to use declarative routes to reduce complexity, regardless of the platform you're targeting (mobile, web, desktop), handling deep linking from Android, iOS and the web while still allowing an easy-to-use developer experience.
https://gorouter.dev
442 stars 96 forks source link

Add /packages directory #79

Closed craiglabenz closed 2 years ago

craiglabenz commented 2 years ago

As preparation for generated route helpers, I've moved all of the relevant package code into /packages/go_router. The plan is to land on the following structure:

/packages
  /go_router
  /go_router_annotation

There is not likely any good reason to merge this until the follow-up go_router_annotation PR is approved; but this is in place to start any package layout discussions and keep the builder / annotation changes more easily read.

The conversation for this started in #66.

kevmoo commented 2 years ago

My vote: don't add packages unless there will be a lot

It's often nicer to have everything at the root – IMHO

I prefer https://github.com/dart-lang/build to https://github.com/dart-lang/test

Just my taste, though 😄

csells commented 2 years ago

Yeah. This one needs revisiting.

craiglabenz commented 2 years ago

FWIW, my inspiration for this idea was Freezed's setup, which allows for keeping freezed (all of the codegen) as a dev dependency, and only requires freezed_annotation to be an actual production dependency.

kevmoo commented 2 years ago

Totally agree with the split. Just my taste is to not make an extra layer of directories

On Sat, Oct 30, 2021, 10:12 Craig Labenz @.***> wrote:

FWIW, my inspiration for this idea was Freezed's setup https://github.com/rrousselGit/freezed/tree/master/packages, which allows for keeping freezed (all of the codegen) as a dev dependency, and only requires freezed_annotation to be an actual production dependency.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/csells/go_router/pull/79#issuecomment-955503109, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAEFCUZBCTOBU4YXLTM733UJQRQRANCNFSM5FUSMLYQ .