Closed somus closed 8 years ago
great was waiting for this to start contributing to this great project 👍
@somus create branch ? v2.0.0 ?
One thing I'm currently missing are server-to-server api calls with credentials (cookies) set. I was working on a form with presaved state which wasn't possible on the server and I ended up using an additional request on the client only.
@carloscuatin Created.
@somus can we assign @weslleyaraujo for implementation of postCSS? as mentioned in #89
@carloscuatin you been assigned anything yet?
@SOSANA I'm working on changing the test runner and possibly add react-intl
although I think the first thing that will work is the file structure so that is not so difficult to add new updates, we agree that the final structure is proposed by @somus in #90 ?
@SOSANA Definitely. I'm not sure whether to have SASS only or PostCSS only or both with CSS Modules. PostCSS looks like a good option. I'm leaning towards pre-processing with SASS and post-processing with PostCSS. @SOSANA @carloscuatin @weslleyaraujo @Ajar-Ajar @evansendra @raksonibs what do you think?
@evansendra and @raksonibs have done a great job in implementing scss in #50 and #81. But, I think we should import and process scss using webpack. For isomorphic support, as I mentioned above webpack isomorphic tools looks like a good option.
@carloscuatin You are right. We should first implement the file structure changes. If the option which I proposed in #90 looks good, I'll get on with implementing it. After that, we can target rest of the features in the list.
@joernroeder You can use something like express session middleware to preserve data on the server side. would this solve your problem?
@somus I'm moving in the file structure
add react-hot-loader version 3 ?
merged in branch v2.0.0 no ?
@somus yes, i'm using the session middleware right now, the main problem was forwarding the requests from the client to the api route during server-side rendering.
Imagine the following example: A client with an active session (logged in) requests an api endpoint directly, sends it's stored session via fetch
with cookies enabled, the middleware on the server connects the request to the session and responds accordingly.
In contrast to the direct client side request is the server the initiator of the fetch
request during ss-rendering and the cookie value needs to be forwarded from the client-->server
to the server-->server
request.
The https://github.com/erikras/react-redux-universal-hot-example claims that:
Both client and server make calls to load data from separate API server
but i had no the time to check it out yet…
@osenvosem Thanks for the suggestion. :) I've been hearing good things about MobX. We even had an AMA with MobX creator at Hashnode. But, it introduces a couple of new concepts and I'm not sure whether it will be beginner friendly. But, we are planning to make mern-cli clone different versions of mern-starter (more details at Hashnode/mern-cli#10). In future, we can fit in a version with MobX there.
@somus actually MobX is more beginner friendly than Redux (which is more complicated). You mark your state as @observable
, you mark react component as @observer
and that's it. With Redux (and several mandatory libs with it) beginners must learn and write much more.
@osenvosem I am quite new to MobX, would it play nice with server side render as well?
good suggestion 💪
@weslleyaraujo I haven't had a need in that yet, but I saw a couple examples of SSR here on github. For example
Getting code coverage configured and installed as part of the package.
@osenvosem, open an issue to discuss Mobx so we can keep the discussion and topics related to mern v2
could it be possible to adapt the Ducks methodolgy so that way we can bundle up the functionality we are creating therefore having some kind of module system that would allow the community to develop modules for the mern stack?
Any plans to add authentication? passport, tokens, social OAuth, the real thing... I think it's pretty basic... every application needs one, and it's not trivial how to set it up in Mern...
@Ajar-Ajar There are a lot of ways to include auth. There is no single universal way to do it. We don't want to add one single method in mern-starter. That's why we are going to make mern-cli clone variants of mern. One of the variants can have social auth, and other can have jwt auth. Through this way, the possibilities are infinite. We are looking to modify mern-cli with this week to make it possible.
Sounds exciting!!! looking forward to see it in action :)
Tree shaking and code splitting with react-router is super super cool!
Good job for you guys. Just wondering if you have any plans about using redux-saga? Thanks!
I know this is closed, but just curious if anyone made or is making a mobx version. I did a mern-cli list but it didn't look like anyone published a variant.
For the past few weeks, we were busy with the development of Hashnode. That's why couldn't give more time to MERN. We are sorry for those pending issues and pull requests. We will close those issues ASAP.
In upcoming weeks, we are planning to release the next version of MERN. This is a discussion thread for what should go in MERN v2. I'm adding a rough list of things what we think would be a great addition to MERN. If you think something should not be there or something else should be there, feel free to comment.
Note: I'll be creating a v2 branch, please make all future PRs against that branch.