Skip to content

Commit

Permalink
🐛 Fix: Correct file structure
Browse files Browse the repository at this point in the history
• Index src as main folder
  • Loading branch information
danielbakas committed Dec 10, 2023
1 parent bf41e22 commit 506b3bb
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 11 deletions.
7 changes: 7 additions & 0 deletions jsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"compilerOptions": {
"paths": {
"@/*": ["./src/*"]
}
}
}
4 changes: 2 additions & 2 deletions src/app/layout.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
import "bootstrap/dist/css/bootstrap.min.css";
import React from "react";
//* Local Imports
import { getMetadata } from "../logic/metadata/service";
import StateManager from "../logic/state/manager";
import { getMetadata } from "@/logic/metadata/service";
import StateManager from "@/logic/state/manager";


//* Main
Expand Down
2 changes: 1 addition & 1 deletion src/app/layout.test.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ vi.mock("@inrupt/solid-ui-react", () => ({
}));

// Mocking the getMetadata function
vi.mock("./logic/metadata/service", () => ({
vi.mock("../logic/metadata/service", () => ({
getMetadata: vi.fn().mockResolvedValue({ /* mock metadata object */ })
}));

Expand Down
4 changes: 2 additions & 2 deletions src/app/page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
import React from "react";
//* Local Imports
import "./page.css";
import Footer from "../components/molecules/footer/component";
import AuthButton from "../components/atoms/authButton";
import Footer from "@/components/molecules/footer/component";
import AuthButton from "@/components/atoms/authButton";


//* Main
Expand Down
2 changes: 1 addition & 1 deletion src/components/atoms/loginButton.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import React, { useEffect, useState } from "react";
import { LoginButton as SolidLoginButton } from "@inrupt/solid-ui-react";
import { Button } from "react-bootstrap";
//* Local imports
import { getOptions } from "../../logic/auth/service";
import { getOptions } from "@/logic/auth/service";


//* Main
Expand Down
2 changes: 1 addition & 1 deletion src/components/molecules/footer/component.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
//* Imports
import Link from "next/link";
//* Local Imports
import useData from "../../../logic/data/hook";
import useData from "@/logic/data/hook";
import FooterLayout from "./layout";


Expand Down
2 changes: 1 addition & 1 deletion src/logic/auth/service.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*/

//* Imports
import { CLIENT_ID, POD_PROVIDER_URI } from "../../services/app/nodes";
import { CLIENT_ID, POD_PROVIDER_URI } from "@/services/app/nodes";

export async function getOptions() {
// Logic
Expand Down
6 changes: 3 additions & 3 deletions src/logic/data/service.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
//* Imports

//* Local Imports
import { APP_WEBID, APP_WEBID_DOC } from "../../services/app/nodes";
import { getProperties, getThing } from "../../services/solid/service";
import { appShape } from "../../services/app/shape";
import { APP_WEBID, APP_WEBID_DOC } from "@/services/app/nodes";
import { getProperties, getThing } from "@/services/solid/service";
import { appShape } from "@/services/app/shape";


//* Main
Expand Down
5 changes: 5 additions & 0 deletions vitest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ import { defineConfig } from "vitest/config";

//* Main
export default defineConfig({
resolve: {
alias: {
"@": "/src",
},
},
test: {
globals: true,
environment: "jsdom",
Expand Down

0 comments on commit 506b3bb

Please sign in to comment.