Create a Windows 8.1 Cordova application by retargeting the project to Windows 8.1,
adding native dependencies, and rebuilding the solution.
Prerequisites
Set up your development environment, and create an Apache Cordova project for Windows 8.1.
See:
- Setting up the Development Environment
- Creating an Apache Cordova Project
Procedure
Retarget the project to Windows 8.1.
- Open your newly created project in Visual Studio 2013.
- You are prompted to retarget the project to Windows 8.1. Click
OK.
- Select the solution in Solution Explorer, right click and select
Retarget to Windows 8.1.
If the operation is successful, you will notice a suffix (Windows 8.1)
next to your project name.
If you are adding a Windows 8.1/Windows Phone 8.1
plugin built using only JavaScript technologies (that is, no native
dependencies), then the plugin installation is complete. Applies to these
plugins:
If you are adding a Windows 8.1/Windows Phone 8.1 plugin built that
depends on native code (see list below), complete these additional steps.
Applies to these plugins:
- Encrypted Storage
- Logon
- AuthProxy
- Logger
Add Native References to the Windows 8.1 project.
- Expand the Project node. Right-Click on References and
click Add Reference.
Add the native Windows DLL or Runtime component that the plugin depends on.
- Click Browse and navigate to the directory that contains
the native dependencies. Note that if the plugin may have different native
library versions for x86 | x64 or
AnyCPU.
- If an AnyCPU version exists, select it. Otherwise,
select x86 or x64.
- Add all the files in that directory (*.dll,
*.winmd)
- If you included an x86 or x64 dependency, specify the dependency.
- Click on Build > Configuration
Manager.
- Select the appropriate CPU architecture (x86 or x64) based on the
dependency CPU architecture under the "Active Solution Platform" and
click Close.
- Rebuild the solution by clicking Build >
Build Solution.
You can now develop your Windows 8.1 application using the plugin.