Comparing version 0.2.9 to 0.2.10
@@ -1,3 +0,3 @@ | ||
import { a as Proxified, P as ProxifiedModule, e as ProxifiedFunctionCall } from './types-823c5240.js'; | ||
import '@babel/types'; | ||
import { a as Proxified, P as ProxifiedModule, e as ProxifiedFunctionCall, g as ProxifiedObject } from './types-823c5240.js'; | ||
import { VariableDeclarator } from '@babel/types'; | ||
import 'recast'; | ||
@@ -48,4 +48,25 @@ | ||
declare function getDefaultExportOptions(magicast: ProxifiedModule<any>): any; | ||
declare function getDefaultExportOptions(magicast: ProxifiedModule<any>): ProxifiedObject<any>; | ||
/** | ||
* Returns the vite config object from a variable declaration thats | ||
* exported as the default export. | ||
* | ||
* Example: | ||
* | ||
* ```js | ||
* const config = {}; | ||
* export default config; | ||
* ``` | ||
* | ||
* @param magicast the module | ||
* | ||
* @returns an object containing the proxified config object and the | ||
* declaration "parent" to attach the modified config to later. | ||
* If no config declaration is found, undefined is returned. | ||
*/ | ||
declare function getConfigFromVariableDeclaration(magicast: ProxifiedModule<any>): { | ||
declaration: VariableDeclarator; | ||
config: ProxifiedObject<any> | undefined; | ||
}; | ||
export { AddVitePluginOptions, UpdateVitePluginConfigOptions, addNuxtModule, addVitePlugin, deepMergeObject, findVitePluginCall, getDefaultExportOptions, updateVitePluginConfig }; | ||
export { AddVitePluginOptions, UpdateVitePluginConfigOptions, addNuxtModule, addVitePlugin, deepMergeObject, findVitePluginCall, getConfigFromVariableDeclaration, getDefaultExportOptions, updateVitePluginConfig }; |
{ | ||
"name": "magicast", | ||
"version": "0.2.9", | ||
"version": "0.2.10", | ||
"description": "Modify a JS/TS file and write back magically just like JSON!", | ||
@@ -40,19 +40,19 @@ "repository": "unjs/magicast", | ||
"dependencies": { | ||
"@babel/parser": "^7.22.4", | ||
"@babel/types": "^7.22.4", | ||
"recast": "^0.23.2" | ||
"@babel/parser": "^7.22.7", | ||
"@babel/types": "^7.22.5", | ||
"recast": "^0.23.3" | ||
}, | ||
"devDependencies": { | ||
"@types/node": "^18.16.16", | ||
"@vitest/coverage-c8": "^0.31.2", | ||
"@vitest/ui": "^0.31.2", | ||
"changelogen": "^0.5.3", | ||
"eslint": "^8.41.0", | ||
"eslint-config-unjs": "^0.2.0", | ||
"lint-staged": "^13.2.2", | ||
"@types/node": "^20.4.5", | ||
"@vitest/coverage-c8": "^0.33.0", | ||
"@vitest/ui": "^0.33.0", | ||
"changelogen": "^0.5.4", | ||
"eslint": "^8.45.0", | ||
"eslint-config-unjs": "^0.2.1", | ||
"lint-staged": "^13.2.3", | ||
"prettier": "^2.8.8", | ||
"simple-git-hooks": "^2.8.1", | ||
"typescript": "^5.0.4", | ||
"simple-git-hooks": "^2.9.0", | ||
"typescript": "^5.1.6", | ||
"unbuild": "^1.2.1", | ||
"vitest": "^0.31.2" | ||
"vitest": "^0.33.0" | ||
}, | ||
@@ -68,3 +68,3 @@ "simple-git-hooks": { | ||
}, | ||
"packageManager": "pnpm@8.6.0" | ||
"packageManager": "pnpm@8.6.10" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
81250
2524
3
Updated@babel/parser@^7.22.7
Updated@babel/types@^7.22.5
Updatedrecast@^0.23.3