Skip to content

Commit 3b1607a

Browse files
authored
Mention tstl on website for improved SEO (#124)
* mention tstl on website for improved SEO * Fix meta tags and recommend installing as dev dependency
1 parent cfb62d6 commit 3b1607a

File tree

2 files changed

+36
-0
lines changed

2 files changed

+36
-0
lines changed

docusaurus.config.js

+6
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@ module.exports = {
66
baseUrl: "/",
77
favicon: "images/favicon.ico",
88
themeConfig: {
9+
metadata: [
10+
{
11+
name: "keywords",
12+
content: "typescript-to-lua, typescript to lua, tstl, typescript, lua, transpiler, compiler",
13+
},
14+
],
915
navbar: {
1016
title: "TypeScriptToLua",
1117
logo: { src: "images/logo.png" },

src/pages/index.tsx

+30
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import Head from "@docusaurus/Head";
12
import Link from "@docusaurus/Link";
23
import useBaseUrl from "@docusaurus/useBaseUrl";
34
import CodeBlock from "@theme/CodeBlock";
@@ -80,6 +81,16 @@ function Feature({ title, description }: Feature) {
8081
export default function Home() {
8182
return (
8283
<Layout>
84+
<Head>
85+
<meta
86+
property="description"
87+
content="TypeScriptToLua (TSTL) is a transpiler that translates TypeScript code to Lua. This allows working with the great type system and tool support of TypeScript, while keeping compatibility with your Lua environment!"
88+
/>
89+
<meta
90+
property="keywords"
91+
content="typescript-to-lua, typescript to lua, tstl, typescript, lua, transpiler, compiler"
92+
/>
93+
</Head>
8394
<header className={`hero ${styles.heroBanner} container`}>
8495
<h1 className={`hero__title ${styles.title}`}>
8596
<b>Type</b>
@@ -122,6 +133,25 @@ export default function Home() {
122133
))}
123134
</div>
124135
</section>
136+
<section className="container">
137+
<div className="row">
138+
<div className={`col`}>
139+
<h1>Getting started</h1>
140+
<p>
141+
Getting started with <b>TSTL</b> is easy, simply install typescript-to-lua from npm:
142+
</p>
143+
<CodeBlock>$ npm install -D typescript typescript-to-lua</CodeBlock>
144+
<p>
145+
You can now run <code>tstl</code> via command line, similar to <code>tsc</code>
146+
</p>
147+
<CodeBlock>$ npx tstl</CodeBlock>
148+
<p>
149+
For more information, see{" "}
150+
<a href={useBaseUrl("docs/getting-started")}>tstl Getting Started documentation</a>.
151+
</p>
152+
</div>
153+
</div>
154+
</section>
125155
</main>
126156
</Layout>
127157
);

0 commit comments

Comments
 (0)