Skip to content

Commit 57071d6

Browse files
authored
Merge pull request #253 from devforth/AdminForth/694
fix: Update tsconfig paths. Update docs
2 parents 831d9c0 + ae11db5 commit 57071d6

File tree

4 files changed

+5
-8
lines changed

4 files changed

+5
-8
lines changed

adminforth/commands/createApp/templates/custom/tsconfig.json.hbs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,8 @@
22
"compilerOptions": {
33
"baseUrl": ".",
44
"paths": {
5-
"@/": "../node_modules/adminforth/dist/spa/src/",
6-
"": "../node_modules/adminforth/dist/spa/node_modules/",
7-
"@@/*": "."
5+
"@/*": ["../node_modules/adminforth/dist/spa/src/*"],
6+
"@@/*": ["./*"]
87
}
98
}
109
}

adminforth/documentation/docs/tutorial/001-gettingStarted.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ Open `index.ts` in your project root and import the new resource:
314314
```ts title="./index.ts"
315315
...
316316
//diff-add
317-
import apartmentsResource from "./resources/apartments";
317+
import apartmentsResource from "./resources/apartments.js";
318318

319319
...
320320
export const admin = new AdminForth({

adminforth/documentation/docs/tutorial/03-Customization/03-virtualColumns.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,6 @@ columns: [
6767
resource: AdminForthResourceCommon;
6868
adminUser: AdminUser
6969
}>();
70-
71-
###
7270
7371
function getFlagEmojiFromIso(iso) {
7472
return iso?.toUpperCase()?.replace(/./g, (char) => String.fromCodePoint(char.charCodeAt(0) + 127397));

adminforth/documentation/docs/tutorial/03-Customization/06-customPages.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ Open `index.ts` file and add the following code *BEFORE* `admin.express.serve(`
310310
311311
app.get(`${ADMIN_BASE_URL}/api/dashboard/`,
312312
admin.express.authorize(
313-
async (req, res) => {
313+
async (req:any, res:any) => {
314314
const days = req.body.days || 7;
315315
const apartsByDays = admin.resource('aparts').dataConnector.client.prepare(
316316
`SELECT
@@ -403,7 +403,7 @@ app.get(`${ADMIN_BASE_URL}/api/dashboard/`,
403403
);
404404
405405
// serve after you added all api
406-
admin.express.serve(app, express)
406+
admin.express.serve(app)
407407
admin.discoverDatabases();
408408
409409
```

0 commit comments

Comments
 (0)