Skip to content

Commit

Permalink
vinvoor: typechecks
Browse files Browse the repository at this point in the history
  • Loading branch information
Topvennie committed Jan 17, 2025
1 parent bf0cf9f commit 49fc9de
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions vinvoor/src/footer/Footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export function Footer() {
<img src={ReactIcon} />
</Icon>
v
{/* @ts-ignore */}

Check failure on line 47 in vinvoor/src/footer/Footer.tsx

View workflow job for this annotation

GitHub Actions / format-and-lint

Use "@ts-expect-error" instead of "@ts-ignore", as "@ts-ignore" will do nothing if the following line is error-free
{__APP_VERSION__}
</Link>
</Tooltip>
Expand Down
10 changes: 5 additions & 5 deletions vinvoor/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ import react from "@vitejs/plugin-react-swc";
import { defineConfig } from "vite";
import svgr from "vite-plugin-svgr";

const generateRandomVersion = () => {
function generateRandomVersion() {
const minor = Math.floor(Math.random() * 10);
const patch = Math.floor(Math.random() * 100).toString().padStart(2, '0');
return `1.${minor}.${patch}`
const patch = Math.floor(Math.random() * 100).toString().padStart(2, "0");
return `1.${minor}.${patch}`;
}

const appVersion = generateRandomVersion();
Expand All @@ -14,6 +14,6 @@ const appVersion = generateRandomVersion();
export default defineConfig({
plugins: [svgr(), react()],
define: {
__APP_VERSION__: JSON.stringify(appVersion)
}
__APP_VERSION__: JSON.stringify(appVersion),
},
});

0 comments on commit 49fc9de

Please sign in to comment.