{"id":25847,"library":"kuikly-ohos-compile-plugin","title":"Kuikly Ohos Compile Plugin","description":"A plugin for unified compilation with Android Studio and DevEco Studio in Kuikly projects. Current version is 0.0.1-alpha.7, alpha status with no fixed release cadence. Key differentiators: integrates Kuikly project compilation into Ohos (OpenHarmony) build pipeline, supports copying assets and configuring native library paths. Low-level tooling, requires manual plugin registration and local.properties configuration.","status":"active","version":"0.0.1-alpha.7","language":"javascript","source_language":"en","source_url":null,"tags":["javascript"],"install":[{"cmd":"npm install kuikly-ohos-compile-plugin","lang":"bash","label":"npm"},{"cmd":"yarn add kuikly-ohos-compile-plugin","lang":"bash","label":"yarn"},{"cmd":"pnpm add kuikly-ohos-compile-plugin","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"Only ESM imports are supported; CJS require will fail.","wrong":"const { kuiklyCompilePlugin } = require('kuikly-ohos-compile-plugin');","symbol":"kuiklyCompilePlugin","correct":"import { kuiklyCompilePlugin } from 'kuikly-ohos-compile-plugin';"},{"note":"Named export only; default import will be undefined.","wrong":"import kuiklyCopyAssetsPlugin from 'kuikly-ohos-compile-plugin';","symbol":"kuiklyCopyAssetsPlugin","correct":"import { kuiklyCopyAssetsPlugin } from 'kuikly-ohos-compile-plugin';"},{"note":"Package has no default export.","wrong":"import KuiklyPlugin from 'kuikly-ohos-compile-plugin';","symbol":"default export","correct":"Not available; use named exports."}],"quickstart":{"code":"// In hvigorfile.ts of ohos project entry module\nimport { kuiklyCompilePlugin, kuiklyCopyAssetsPlugin } from 'kuikly-ohos-compile-plugin';\n\nexport default {\n    // ... other config\n    plugins: [\n        kuiklyCompilePlugin(),\n        kuiklyCopyAssetsPlugin({ assetsPath: process.env.KUIKLY_ASSETS_PATH ?? '/path/to/assets' })\n    ]\n};","lang":"typescript","description":"Shows registration of both compile and copy assets plugins in a hvigorfile.ts with required imports."},"warnings":[{"fix":"Monitor Hvigor updates and migrate to new configuration format if provided.","message":"Plugin configuration uses local.properties which may be deprecated in future Hvigor versions.","severity":"deprecated","affected_versions":">=0.0.1"},{"fix":"Pin to a specific version and test upgrades thoroughly.","message":"Alpha version potentially breaking changes without migration guides.","severity":"breaking","affected_versions":">=0.0.0"},{"fix":"Ensure .ohpmrc contains the correct registry entry.","message":"Requires registry=https://registry.npmjs.org/ in .ohpmrc for dependency resolution.","severity":"gotcha","affected_versions":">=0.0.1"},{"fix":"Add all required properties to local.properties.","message":"Mandatory local.properties keys: kuikly.projectPath, kuikly.moduleName, kuikly.ohosGradleSettings. Missing these causes build failure.","severity":"gotcha","affected_versions":">=0.0.1"},{"fix":"Add parentheses: kuiklyCompilePlugin() instead of kuiklyCompilePlugin.","message":"Plugin functions must be called (e.g., kuiklyCompilePlugin()) not passed as references.","severity":"gotcha","affected_versions":">=0.0.1"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Add 'kuikly-ohos-compile-plugin': 'latest' to hvigor/hvigor-config.json5 dependencies and set registry in .ohpmrc.","cause":"Ohos project not configured with npm registry in .ohpmrc or dependency not added.","error":"Cannot find module 'kuikly-ohos-compile-plugin'"},{"fix":"Add kuikly.projectPath, kuikly.moduleName, and kuikly.ohosGradleSettings to local.properties.","cause":"Missing mandatory local.properties entries.","error":"Property 'kuikly.projectPath' not set"},{"fix":"Use import { kuiklyCompilePlugin } from 'kuikly-ohos-compile-plugin' and call it as kuiklyCompilePlugin().","cause":"Using wrong import style or incorrect symbol name.","error":"TypeError: kuikly_ohos_compile_plugin_1.kuiklyCompilePlugin is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}