Skip to content

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

adminforth/commands/createApp/utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ export async function promptForMissingOptions(options) {
8484
questions.push({
8585
type: 'select',
8686
name: 'useNpm',
87-
message: 'Select your package manager ->',
87+
message: 'Select your package manager >',
8888
choices: [
8989
{ name: 'pnpm', value: false },
9090
{ name: 'npm', value: true },

adminforth/modules/codeInjector.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { ADMIN_FORTH_ABSOLUTE_PATH, getComponentNameFromPath, transformObject, d
1111
import { ICodeInjector } from '../types/Back.js';
1212
import { StylesGenerator } from './styleGenerator.js';
1313
import { afLogger } from '../modules/logger.js';
14+
import { pathToFileURL } from 'url';
1415

1516

1617
let TMP_DIR;
@@ -97,7 +98,7 @@ class CodeInjector implements ICodeInjector {
9798
const iconPackageNames = Array.from(collections).map((collection) => `@iconify-prerendered/vue-${collection}`);
9899

99100
const iconPackages = (
100-
await Promise.allSettled(iconPackageNames.map(async (pkg) => ({ pkg: await import(this.spaTmpPath() +'/node_modules/' + pkg), name: pkg})))
101+
await Promise.allSettled(iconPackageNames.map(async (pkg) => ({ pkg: await import(pathToFileURL(path.join(this.spaTmpPath(), 'node_modules', pkg)).href), name: pkg})))
101102
);
102103

103104
const loadedIconPackages = iconPackages.filter(isFulfilled).map((res) => res.value).reduce((acc, { pkg, name }) => {

0 commit comments

Comments
 (0)