Official website immux.com is powered by Gatsby, where our important info and blog run.
-
Simply Responsive (with Bootstrap v4)
-
i18n
-
Blog with markdown
-
SSR (to be done)
-
Basic SEO
npm install -g gatsby-cli
gatsby developJust create a .tsx file under src/pages, and then you will got a route with the filename, www.immux.com/products .eg.
- Create a directory under
contentdirectory - Create a file with
index.mdsuffix under the directory you just created. - Follow the example under
contentdirectory, expecially the spectial comment on the top of the markdown file.
That's all.
Checkout the src/intl directory. Add any keywords you like in the locale file under that directory, and use the keywords in your components.
import { FormattedMessage } from "gatsby-plugin-intl";
<FormattedMessage id="" />;
// id is the keywords you defined in the locale file, which support chain style, like `home.hero.tilte` .eg.import { useIntl } from "gatsby-plugin-intl";
const intl = useIntl();
intl.formatMessage({ id: "subscription.subscribeBtn" });If you have problem with the i18n, you can check the following steps:
- check your
idspelling - If the solution above doesn't work, you can excute the command under your project root:
gatsby clean, and then restart your development server.
Checkout the i18n plugin documentation.
Deploy
npm run deploy
# Then in the public directory will be files to copy to the server.Checkout it out here if any problem.
/src/scss/gatstrap.scss
