Add missing meta tag
This commit is contained in:
parent
8238d21f2f
commit
6f12dbbfa4
|
@ -1,3 +1,5 @@
|
||||||
node_modules
|
node_modules
|
||||||
package-lock.json
|
package-lock.json
|
||||||
dev.html
|
dev.html
|
||||||
|
*.js.map
|
||||||
|
*.js
|
|
@ -4,7 +4,9 @@
|
||||||
"description": "Generate an open graph image for twitter/facebook/etc",
|
"description": "Generate an open graph image for twitter/facebook/etc",
|
||||||
"main": "card.js",
|
"main": "card.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "node card.js"
|
"start": "node card.js",
|
||||||
|
"build": "tsc",
|
||||||
|
"watch": "tsc --watch"
|
||||||
},
|
},
|
||||||
"author": "styfle",
|
"author": "styfle",
|
||||||
"repository": "github:styfle/og-image",
|
"repository": "github:styfle/og-image",
|
||||||
|
|
|
@ -44,6 +44,9 @@ function getCss(fontWeight: FontWeight, fontSize: string) {
|
||||||
|
|
||||||
export function getHtml(text: string, fontWeight: FontWeight, fontSize: string, images: string[]) {
|
export function getHtml(text: string, fontWeight: FontWeight, fontSize: string, images: string[]) {
|
||||||
return `<html>
|
return `<html>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<title>Generated Image</title>
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
<style>
|
<style>
|
||||||
${getCss(fontWeight, fontSize)}
|
${getCss(fontWeight, fontSize)}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue