Skip to content

Commit

Permalink
refactor: code structure
Browse files Browse the repository at this point in the history
  • Loading branch information
DaPotatoMan committed Apr 4, 2024
1 parent d9488b7 commit e111506
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 8 deletions.
2 changes: 2 additions & 0 deletions src/core/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './types'
export * from './utils'
File renamed without changes.
File renamed without changes.
5 changes: 1 addition & 4 deletions src/module.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
import process from 'node:process'

import { addPrerenderRoutes, addServerPlugin, createResolver, defineNuxtModule } from '@nuxt/kit'

import { transformManifests } from './vite/utils'
import type { MSOfficeAddinConfig } from './vite/types'
import { type MSOfficeAddinConfig, transformManifests } from './core'

export default defineNuxtModule<MSOfficeAddinConfig>({
meta: {
Expand Down
2 changes: 1 addition & 1 deletion src/runtime/loader.server.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { defineNitroPlugin } from 'nitropack/runtime'
import type { OfficeAddinVirtualContext } from '../vite/types'
import type { OfficeAddinVirtualContext } from '../core'

// @ts-expect-error virtual import
import context from '#office-addin-content'
Expand Down
4 changes: 1 addition & 3 deletions src/vite/index.ts → src/vite.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
import process from 'node:process'

import type { Plugin, UserConfig } from 'vite'
import type { MSOfficeAddinConfig } from './types'
import { OFFICE_JS_LOADER_SNIPPET, transformManifests } from './utils'
import { type MSOfficeAddinConfig, OFFICE_JS_LOADER_SNIPPET, transformManifests } from './core'

export default function MSOfficeAddin(params: MSOfficeAddinConfig): Plugin {
let mode: string
Expand Down

0 comments on commit e111506

Please sign in to comment.