mirror of
https://github.com/LemmyNet/joinlemmy-site.git
synced 2024-11-28 15:21:18 +00:00
Remove unnecessary releases.
This commit is contained in:
parent
30b847062c
commit
3f5452ab92
3 changed files with 0 additions and 49 deletions
|
@ -41,17 +41,6 @@ try {
|
||||||
console.error(err);
|
console.error(err);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Write the releases file
|
|
||||||
try {
|
|
||||||
const markdown = await (await fetch(releasesLocation)).text();
|
|
||||||
let data = `export const releases_md = \n `;
|
|
||||||
data += JSON.stringify(markdown, null, 2) + ";";
|
|
||||||
const target = outDir + "releases.ts";
|
|
||||||
fs.writeFileSync(target, data);
|
|
||||||
} catch (err) {
|
|
||||||
console.error(err);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Write the translations
|
// Write the translations
|
||||||
fs.readdir(translationDir, (_err, files) => {
|
fs.readdir(translationDir, (_err, files) => {
|
||||||
files.forEach(filename => {
|
files.forEach(filename => {
|
||||||
|
|
|
@ -1,32 +0,0 @@
|
||||||
import { Component } from "inferno";
|
|
||||||
import { Helmet } from "inferno-helmet";
|
|
||||||
import { i18n } from "../i18next";
|
|
||||||
import { releases_md } from "../translations/releases";
|
|
||||||
import { mdToHtml, isBrowser } from "../utils";
|
|
||||||
|
|
||||||
const title = i18n.t("releases");
|
|
||||||
|
|
||||||
export class Releases extends Component<any, any> {
|
|
||||||
constructor(props: any, context: any) {
|
|
||||||
super(props, context);
|
|
||||||
}
|
|
||||||
|
|
||||||
componentDidMount() {
|
|
||||||
if (isBrowser()) {
|
|
||||||
window.scrollTo(0, 0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
render() {
|
|
||||||
return (
|
|
||||||
<div>
|
|
||||||
<Helmet title={title}>
|
|
||||||
<meta property={"title"} content={title} />
|
|
||||||
</Helmet>
|
|
||||||
<div class="container">
|
|
||||||
<div dangerouslySetInnerHTML={mdToHtml(releases_md)} />
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -7,7 +7,6 @@ import { Donate } from "./components/donate";
|
||||||
import { About } from "./components/about";
|
import { About } from "./components/about";
|
||||||
import { News } from "./components/news";
|
import { News } from "./components/news";
|
||||||
import { NewsItem } from "./components/news-item";
|
import { NewsItem } from "./components/news-item";
|
||||||
import { Releases } from "./components/releases";
|
|
||||||
|
|
||||||
export const routes: IRouteProps[] = [
|
export const routes: IRouteProps[] = [
|
||||||
{
|
{
|
||||||
|
@ -25,11 +24,6 @@ export const routes: IRouteProps[] = [
|
||||||
exact: true,
|
exact: true,
|
||||||
component: News,
|
component: News,
|
||||||
},
|
},
|
||||||
{
|
|
||||||
path: `/releases`,
|
|
||||||
exact: true,
|
|
||||||
component: Releases,
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
path: `/news/:title`,
|
path: `/news/:title`,
|
||||||
exact: true,
|
exact: true,
|
||||||
|
|
Loading…
Reference in a new issue