Conventions used
There are a number of text conventions used throughout this book.
Code in text
: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: “The root of the routes
folder maps to the /
-path.”
A block of code is set as follows:
import { H1 } from '~/components/headings'; export default function LoginPage() { return ( <main> <H1>Login!</H1> </main> ); }
When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:
<Routes> <Route file="root.tsx"> <Route index file="routes/index.tsx" /> <Route path="demo" file="routes/demo.tsx" /> </Route> </Routes>
Any command-line input or output is written as follows:
npx remix routes
Bold: Indicates a new term, an important word, or words that you see on screen. For instance, words in menus or dialog boxes appear in bold. Here is an example: “Notice that one route is flagged as index, while the demo route has a path property, which matches its filename.”
Tips or important notes
Appear like this.