NativeScript / nativescript-dev-webpack

A package to help with webpacking NativeScript apps.
Apache License 2.0
97 stars 49 forks source link

Error: In order to generate a V8 snapshot you must have the "android" platform installed - to do so please run "tns platform add android". #1149

Closed mapo80 closed 3 years ago

mapo80 commented 3 years ago

Environment Provide version numbers for the following components (information can be retrieved by running tns info in your project folder or by inspecting the package.json of the project):

Describe the bug I use @nativescript/webpack version 3.0.0 and NS 7. With latest version of NS there is new configuration file "nativescript.config.ts", but getAndroidRuntimeVersion reads info from package.json

const getAndroidRuntimeVersion = (projectDir) => {
    try {
        const projectPackageJSON = getPackageJson(projectDir);

        const version = projectPackageJSON["nativescript"]["tns-android"]["version"];
        return version && toReleaseVersion(version);
    } catch (e) {
        return null;
    }
}

To Reproduce

Expected behavior

Sample project

Additional context

mapo80 commented 3 years ago

Here there are more details: https://github.com/NativeScript/NativeScript/issues/8875