Skip to content

Commit f803ca5

Browse files
committed
i've tried 😿
1 parent 19fb6de commit f803ca5

File tree

8 files changed

+13
-21
lines changed

8 files changed

+13
-21
lines changed

‎src/codeforces/code.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ const Coder = () => {
88
const [hacks, setHacks] = useState({});
99

1010
useEffect(() => {
11-
fetch(`${import.meta.env.VITE_API_URL}codes/codeforces/${id}`)
11+
fetch(`https://nexus-api-note-co-78.deno.dev/codes/codeforces/${id}`)
1212
.then(async (res) => await res.json())
1313
.then(([json]) => setHacks(json));
1414

‎src/codeforces/index.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ const Hk = () => {
55
const [hacks, setHacks] = useState([]);
66

77
useEffect(() => {
8-
fetch(`${import.meta.env.VITE_API_URL}codes/codeforces`)
8+
fetch(`https://nexus-api-note-co-78.deno.dev/codes/codeforces`)
99
.then(async (res) => await res.json())
1010
.then((json) => setHacks(json));
1111

‎src/hackerank/code.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ const Hack = () => {
88
const [hacks, setHacks] = useState({});
99

1010
useEffect(() => {
11-
fetch(`${import.meta.env.VITE_API_URL}codes/hackerank/${id}`)
11+
fetch(`https://nexus-api-note-co-78.deno.dev/codes/hackerank/${id}`)
1212
.then(async (res) => await res.json())
1313
.then(([json]) => setHacks(json));
1414

‎src/hackerank/index.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ const Hk = () => {
55
const [hacks, setHacks] = useState([]);
66

77
useEffect(() => {
8-
fetch(`${import.meta.env.VITE_API_URL}codes/hackerank`)
8+
fetch(`https://nexus-api-note-co-78.deno.dev/codes/hackerank`)
99
.then(async (res) => await res.json())
1010
.then((json) => setHacks(json));
1111

‎src/omegaup/code.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ const Op = () => {
88
const [hacks, setHacks] = useState({});
99

1010
useEffect(() => {
11-
fetch(`${import.meta.env.VITE_API_URL}codes/omegaup/${id}`)
11+
fetch(`https://nexus-api-note-co-78.deno.dev/codes/omegaup/${id}`)
1212
.then(async (res) => await res.json())
1313
.then(([json]) => setHacks(json));
1414

‎src/omegaup/index.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ const Hk = () => {
66

77
useEffect(() => {
88
console.log(import.meta.env.VITE_API_URL);
9-
fetch(`${import.meta.env.VITE_API_URL}codes/omegaup`)
9+
fetch(`$https://nexus-api-note-co-78.deno.dev/codes/omegaup`)
1010
.then(async (res) => await res.json())
1111
.then((json) => setHacks(json));
1212

‎src/utils/input.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const input = () => {
1111
});
1212
const send = () => {
1313
// console.log(dato);
14-
fetch(`${import.meta.env.VITE_API_URL}code/${pt}`, {
14+
fetch(`https://nexus-api-note-co-78.deno.dev/code/${pt}`, {
1515
method: 'POST',
1616
headers: {
1717
'Content-Type': 'application/json'

‎vite.config.ts‎

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,13 @@
1-
import { defineConfig, loadEnv } from 'vite'
1+
import { defineConfig } from 'vite'
22
import deno from '@deno/vite-plugin'
33
import react from '@vitejs/plugin-react-swc'
44
import tailwindcss from 'tailwindcss'
5-
import process from "node:process"
65
// https://vite.dev/config/
7-
export default defineConfig(({mode}) => {
8-
const env = loadEnv(mode, process.cwd(), '');
9-
return {
10-
11-
plugins: [deno(), react()],
12-
css: {
13-
postcss: {
14-
plugins: [tailwindcss()],
15-
}
16-
},
17-
define: {
18-
'import.meta.env.VITE_API_URL': JSON.stringify(env.VITE_API_URL)
6+
export default defineConfig({
7+
plugins: [deno(), react()],
8+
css: {
9+
postcss: {
10+
plugins: [tailwindcss()],
1911
}
2012
}
2113
})

0 commit comments

Comments
 (0)