Getting Started

Getting Started

Getting started with the Xweather JavaScript SDK requires that you have an active Xweather account and have determined which implementation method you wish to use as detailed below.

Start Using the SDK

You'll need to follow a series of steps to get started using the Xweather JavaScript SDK:

  1. Sign up for an Xweather Weather API subscription service and setup your access keys as described in our Xweather Weather API's getting started guide. We offer a free developer account for you to give our weather API a test drive.
  2. Decide on your method of integration, either by loading the SDK in the browser or using it as an NPM module.

Script Usage vs NPM Module

The Xweather JavaScript SDK supports both browser-based inclusion and NodeJS module implementations depending on your project's needs. In most cases, using the browser-based include method is the recommended method as it offers the fastest and easiest setup. However, if you're building your application using NPM libraries or with a NodeJS server that doesn't require a browser, then the NodeJS module would work.

Browser ScriptNPM Module
Easier to get startedRequires more setup to get started
Already compiled to support ES5+Must setup up a module bundler for browser usage
Limited library access using facade methodsFull access to library classes and utilities
Must include entire script files regardless of usageMore control over which classes and features are included in your project