Repository navigation
Replies: 5 comments 1 reply
|
I have been using remix, nx at work for the last 6 months. Allowing the user to specify the directory in I have hosted my remix / nx applications on netlify and vercel, and I think the proposed solution would also simplify deployments on those platforms. |
|
+1 |
|
+1 we also use an NX integrated monorepo and being forced to use a package.json per remix app goes against the grain of why we chose an integrated monorepo in the first place. surely this could be as simple as a config setting as mentioned above? |
|
At least with the vite version of remix, remix seems to work fine on an integrated repo. on the vite config per project, just need to the ff vite config. export default defineConfig({
root: path.resolve(__dirname, "../.."), // resolves to workspace dir
plugins: [
remix({
appDirectory: path.resolve(__dirname, "app"),
}),
tsconfigPaths(),
],
});And execute the equivalent of: Don't forget to clear out |
|
This discussion is being closed as part of the Remix v3 repository cleanup. Remix v1/v2 was upstreamed into React Router v7, so if this proposal is still relevant, please reopen or continue the discussion in the React Router repository. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi all,
I've recently began a project where I am using remix with an
nxmonorepo.nxhas a experimental remix plugin: https://nx.dev/recipes/other/remix, code here.But one of the issues is that remix needs a
package.jsonfile to work, whilenxproposes to have 1 global package.json - and this discussion isn't really to weigh up the pros/cons of each approach, its more to allow users to have the flexibility to go with either.The code that blocks this from working, from what I can tell is part of the
remix-devpackage:The current implementation throws an error if a package.json doesn't exist.
A simple solution would be to allow users to specify the directory their
package.jsonis in, relative to theremix.config.jsfile.Would be good to get peoples thoughts on this before opening a PR
EDIT: an alternative approach would be to use pkg-up as a fallback where there is no package.json in the remix root, shout out to @rossipedia for the suggestion
All reactions