Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redirect all routes to the same component #55

Closed
beeb opened this issue Jan 19, 2015 · 2 comments
Closed

Redirect all routes to the same component #55

beeb opened this issue Jan 19, 2015 · 2 comments

Comments

@beeb
Copy link

beeb commented Jan 19, 2015

Hello,

I'm building a single page application which has only 1 component/page. I'd like to redirect all uri's to this "Index" component, instead of having the 404 page showing up for invalid routes. Is that possible ? I tried putting regular expressions inside routes in the app.js but it doesn't seem to work.

Thanks !

koistya added a commit that referenced this issue Feb 8, 2015
 - Refactor webpack config
 - Generate source maps in debug mode
 - Create two bundles during a build - `./build/app.js` (client-side) and `./build/server.js` (server-side)
 - Replace the original JSX transpiler with 6to5
 - Register core-js polyfills
 - Clean up the top-level React component (App)
 - Load page content asynchronously
 - Remove `./src/images` folder and `images` Gulp task in favor of images-per-component

Closes #57, #55, #53,  #4
@koistya
Copy link
Member

koistya commented Feb 8, 2015

@beeb check it out, it now has a single top-level component (./src/components/App) and all page URLs are now handled by it.

@koistya koistya closed this as completed Feb 8, 2015
@beeb
Copy link
Author

beeb commented Feb 9, 2015

Thanks, but this seems to change significantly from the previous version and I'm not sure I'm willing to update my project to use the new code. Any way to do it with Director ?

vishwanatharondekar added a commit to vishwanatharondekar/react-starter-kit that referenced this issue Oct 16, 2015
 - Refactor webpack config
 - Generate source maps in debug mode
 - Create two bundles during a build - `./build/app.js` (client-side) and `./build/server.js` (server-side)
 - Replace the original JSX transpiler with 6to5
 - Register core-js polyfills
 - Clean up the top-level React component (App)
 - Load page content asynchronously
 - Remove `./src/images` folder and `images` Gulp task in favor of images-per-component

Closes kriasoft#57, kriasoft#55, kriasoft#53,  kriasoft#4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants