A way back out, and the tags a crawler reads
The same two gaps the wumpus had, closed the same way, because they are the same site. The way back sits leftmost in the footer, next to SOURCE, and the arrow is a pseudo-element so it can be the right arrow for the skin: a chevron on the remaster, and the two ASCII characters the Atari's character set actually had on the 1979 one. Absolute rather than "/", because this game is served from a subdirectory in production and from the root in development -- the relative answer is right in one of those and points at the game itself in the other. The head gains canonical, Open Graph, Twitter and robots, plus VideoGame and BreadcrumbList structured data. Canonical is not boilerplate here: the container falls back to index.html for anything under /lemonade/, so without it /lemonade/anything-at-all is a separate indexable page with the same content. The preview image is served by the site rather than added here. Every pixel of this game is SVG drawn in code and there are no artwork files; a social card is not part of the game, and it belongs with the deployment. A noscript block describes the game and links onwards rather than leaving an empty div for a reader without scripts. Build clean.
This commit is contained in:
+19
@@ -28,6 +28,17 @@ import './App.css'
|
||||
*/
|
||||
const SOURCE_URL = 'https://github.com/Coffey-Labs/lemonade'
|
||||
|
||||
/**
|
||||
* The way back out.
|
||||
*
|
||||
* Absolute rather than `/`, because this game is served from a subdirectory in
|
||||
* production and from the root in development -- so the relative answer is
|
||||
* right in one of those and points at the game itself in the other. The
|
||||
* destination is a particular site, and naming it is the honest way to say so.
|
||||
* The source link next to it works the same way for the same reason.
|
||||
*/
|
||||
const GAMES_URL = 'https://games.jcoffey.dev/'
|
||||
|
||||
export default function App() {
|
||||
const [seed] = useState(randomSeed)
|
||||
const [state, dispatch] = useReducer(reducer, seed, initialState)
|
||||
@@ -213,6 +224,14 @@ export default function App() {
|
||||
<Crt
|
||||
footer={
|
||||
<div className="controls">
|
||||
{/* Leftmost, because that is where a way back belongs. */}
|
||||
<a
|
||||
className="btn btn-ghost back"
|
||||
href={GAMES_URL}
|
||||
title="The rest of the games"
|
||||
>
|
||||
GAMES
|
||||
</a>
|
||||
<Btn
|
||||
kind="ghost"
|
||||
onClick={() => {
|
||||
|
||||
Reference in New Issue
Block a user