File tree Expand file tree Collapse file tree
analytics/modules/analytics Expand file tree Collapse file tree Original file line number Diff line number Diff line change 88} from 'wxt/modules' ;
99import { relative , resolve } from 'node:path' ;
1010import type { AnalyticsConfig } from './types' ;
11+ import { normalizePath } from 'wxt' ;
1112
1213declare module 'wxt/utils/define-app-config' {
1314 export interface WxtAppConfig {
@@ -42,7 +43,7 @@ export default defineWxtModule({
4243 `import { createAnalytics } from '${
4344 process . env . NPM
4445 ? clientModuleId
45- : relative ( wxtAnalyticsFolder , clientModuleId )
46+ : normalizePath ( relative ( wxtAnalyticsFolder , clientModuleId ) )
4647 } ';`,
4748 `import { useAppConfig } from '#imports';` ,
4849 `` ,
Original file line number Diff line number Diff line change @@ -2,8 +2,8 @@ import systemPath from 'node:path';
22import normalize from 'normalize-path' ;
33
44/**
5- * Converts system paths to normalized bundler path.\
6- * On Windows and Unix , this returns paths with `/` instead of `\`.
5+ * Converts system paths to normalized bundler path.
6+ * On Windows, this returns paths with `/` instead of `\`.
77 */
88export function normalizePath ( path : string ) : string {
99 return normalize ( path ) ;
You can’t perform that action at this time.
0 commit comments