React component for 404 page with animations.
Note: You needs npm version >= 7 to install peer dependencies automatically.
npm install --save-dev react-space-404
Talk is cheap. Here the code is.
import Space404 from 'react-space-404';
<Space404 palette={custom_palette} countdown={10} href="/redirect" />
// simplifed Chinese with default wordings and no redirects
<Space404 language="chs" stay />
// with customized wordings
<Space404 i18n={i18n_protoss} language="protoss" />
-
palette
custom colors.
-
countdown
redirect countdown in seconds.
-
redirect
URL that redirect to when time is up.
-
i18n
i18next instance, reference.
-
language
language name in string, the built-in i18n instance supports
chs
anden
.the default value is
en
. -
stay
stay in this page without redirect.
the default value is
false
.
- React
- MUI(Material UI)
- gsap
Powered by storybook, use npm run storybook
to start the dev server.
Powered by jest, use npm test
to run tests.
- Component
- i18n
- The astronaut vector image: catalyststuff
- Stars vector images: svgrepo
MIT License.