模版中web组件路径调整
This commit is contained in:
parent
2980a10287
commit
3b1ae9a27b
|
|
@ -1,7 +1,6 @@
|
|||
import initialize from '@project/initialize';
|
||||
import { createComponent } from '@project/page';
|
||||
import { host } from './configuration';
|
||||
const { features } = initialize('native', host);
|
||||
const { features } = initialize();
|
||||
|
||||
Object.assign(global, {
|
||||
features,
|
||||
|
|
|
|||
|
|
@ -1,7 +1,4 @@
|
|||
const { initialize } = require('@xuchangzju/oak-cli/lib/server/initialize');
|
||||
const {
|
||||
BackendRuntimeContext,
|
||||
} = require('../lib/context/BackendRuntimeContext');
|
||||
|
||||
const pwd = process.cwd();
|
||||
|
||||
|
|
|
|||
|
|
@ -8,9 +8,7 @@ import {
|
|||
OakServerProxyException,
|
||||
} from 'oak-domain/lib/types/Exception';
|
||||
import { ECode } from 'oak-frontend-base/es/types/ErrorPage';
|
||||
const ErrorPage = lazy(
|
||||
() => import('oak-frontend-base/es/components/errorPage')
|
||||
);
|
||||
const ErrorPage = lazy(() => import('oak-frontend-base/es/components/errorPage'));
|
||||
|
||||
interface ErrorProps {
|
||||
error: any;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ import React from 'react';
|
|||
import { Routes, Route, Outlet, useLocation } from 'react-router-dom';
|
||||
import { IRouter, IBrowserRouterProps, IMeta } from './types/router';
|
||||
import routers from './app/routers';
|
||||
import Loading from './components/Loading';
|
||||
import Loading from './app/components/Loading';
|
||||
import useFeatures from '@project/hooks/useFeatures';
|
||||
|
||||
type TRenderRoutes = (
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
|
||||
import React, { useEffect, useState } from 'react';
|
||||
import { Routes, Route, Outlet, useLocation } from 'react-router-dom';
|
||||
import Header from '../../components/consoleHeader';
|
||||
import Header from '../../components/header';
|
||||
import Styles from './web.pc.module.less';
|
||||
import useFeatures from '@project/hooks/useFeatures';
|
||||
// import Menu from '@project/components/console/menu';
|
||||
|
|
|
|||
|
|
@ -1,5 +0,0 @@
|
|||
"use oak router builder"; // 这行备注说明是用oak的router builder来生成allRouters
|
||||
import React from 'react';
|
||||
import { IRouter } from '../../types/router';
|
||||
let allRouters: IRouter[] = [];
|
||||
export default allRouters;
|
||||
|
|
@ -1,12 +1,8 @@
|
|||
|
||||
import initialize from '@project/initialize';
|
||||
import { createComponent } from '@project/page';
|
||||
import { host } from './configuration';
|
||||
import { getAppType } from './utils/env';
|
||||
|
||||
const appType = getAppType();
|
||||
|
||||
const { features } = initialize(appType, host);
|
||||
const { features } = initialize();
|
||||
|
||||
Object.assign(global, {
|
||||
features,
|
||||
|
|
|
|||
Loading…
Reference in New Issue