Migrating a website (HTML)

[This article is for Windows 8.x and Windows Phone 8.x developers writing Windows Runtime apps. If you’re developing for Windows 10, see the latest documentation]

Here you'll find specific considerations and steps to follow when you port a basic website to a Windows Store app using JavaScript. Specifically, we'll discuss the security and performance considerations for developing a Windows Store app using JavaScript with online connectivity and a specific server component.

For information about porting the front-end components of your website to a Windows Store app using JavaScript, see Migrating your web app.

Porting considerations

A Windows Store app using JavaScript behaves as a typical webpage, and can communicate with a web server or peers if you enable the proper security level and permissions. (See Features and restrictions by context.) A Windows Store app using JavaScript is hosted by the WWAHost.exe process, which contains all the functionality of Microsoft Internet Explorer 10. However, because WWAHost.exe has access to the Windows Runtime, and therefore to operating system (OS)-level functionality, you must consider the following:

  • Will you incorporate your back-end, middle-tier, and/or business logic components into the Windows Store app using JavaScript using the WinRT APIs, or will they remain as separate resources?
  • If they are separate, will they run on a server or a peer within the local area network, an intranet or specific subdomain, or the Internet?
  • How do you transmit data? Secure Sockets? Plaintext? A syndication component? Do you have an authorization or authentication model separate from the Windows Identity model?
  • How do you plan to deploy your application? In the Windows Store, or via side-loading?
  • Can some functionality be moved to the client, now that you have access to a broader spectrum of client features and behaviors?

The Windows Runtime provides several namespaces and classes for communication, streaming, security, client package deployment, data sharing, and syndication. The following table lists these namespaces and their contents:

Namespace/Class Description
Windows.ApplicationModel.Search Defines the classes for implementing the Windows search pane in an app. The search pane is a touch-friendly search box that offers type-ahead suggestions to the user. Using the search pane in your application gives the user a way to enter search queries that is consistent with other apps.
Windows.Data.Html Defines a set of utility classes for working with HTML.
Windows.Data.Json Defines the interfaces and classes needed to parse a JavaScript Object Notation (JSON) string into an object in memory, and to serialize that object back into a JSON string. The objects in this namespace represent all of the forms of a JSON value that are defined in the JSON schema and are enumerated as types in the JsonValueType enumeration: null, Boolean, number, string, array, and object.
Windows.Management.Deployment Defines types that provide functionality for managing Windows Store app packages in Windows 8. Functionality includes API elements to add, update, remove, stage, register, and enumerate packages.
Windows.Media Defines classes for creating and working with media such as photos, audio recordings and videos.
Windows.Media.PlayTo Defines classes and interfaces for streaming audio, video, and images to remote devices.
Windows.Networking.BackgroundTransfer Defines classes for advanced download and upload transfer capabilities within an app.
Windows.Networking.Connectivity Defines types used in a cost-aware application. Specifically, it defines the types that can tell the application exactly how much certain activities (such as a large download on a metered connection) will cost in terms of usage data.
Windows.Networking.NetworkOperators Defines classes that support mobile broadband account management.
Windows.Networking.PushNotifications Defines classes and interfaces that encapsulate push notifications for network events.
Windows.Networking.Sockets Defines classes that are used to define networking sockets (such as datagram, stream, and web) for both local subnet and Internet-aware connections.
Windows.Security.Authentication.OnlineId Defines classes that enable Windows Store apps to use Windows Live to authenticate users using their Microsoft account. After authentication, apps can get back a JSON token with an ID that can be used for that user with your app.
Windows.Security.Authentication.Web Defines classes that enable Windows Store apps to integrate with online web services, such as Facebook, without exposing a user's credentials. This is accomplished by using protocols like OAuth and OpenID.
Windows.Security.Credentials Defines classes for securely storing and managing user passcodes, passphrases, and other identification information.
Windows.Security.Cryptography.Certificates Defines classes that you can use to create certificate requests and install certificate responses.
Windows.Security.Cryptography.DataProtection Defines classes that enables you to easily encrypt and decrypt static data or a data stream.
Windows.Web.AtomPub Defines the classes, delegates, and interfaces needed to implement the AtomPub protocol. This protocol enables HTTP CRUD access to Web resources by using the Atom 1.0 wire format.
Windows.Web.Syndication Defines the types that provide functionality for managing syndication feeds.

 

Design case study: Enterprise line of business Windows Store app