Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Should react-router-dom be utilized on the server or is there a suitable replacement? #2

Open
@deanrad

Description

It raised an eyebrow to see a dependency on react-router-dom in the server/handlerRender.js file, since it's a client library being utilized on the server.

import { matchPath } from 'react-router-dom';

From Michael Jackson's guide you referenced: https://reacttraining.com/react-router/web/guides/server-rendering, there's a /server folder which might be more appropriate. As a code reviewer I'd be less concerned about the latter than the former..

import ReactDOMServer from 'react-dom/server'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /