Module to work alongside OpenLayers for reading WFS Capabilities data (versions 1.0.0, 1.1.0 and 2.0.0) and convert it to JSON, complementing the native classes ol/format/WMSCapabilities
and ol/format/WMTSCapabilities
.
OpenLayers (at least up to 8.1.0 version) does not have a native way to do this (see related issue), hence the creation of this module that does not depend on any other external dependency other than what comes with OpenLayers.
See converter to text and parse data
import WFSCapabilities from 'ol-wfs-capabilities';
const parser = new WFSCapabilities();
const parsedCapabilities = parser.read(myWfsCapabilitiesSource);
See CHANGELOG for details of changes in each release.
NPM package: ol-wfs-capabilities.
Install the package via npm
npm install ol-wfs-capabilities
TypeScript types are shipped with the project in the dist directory and should be automatically used in a TypeScript project. Interfaces are provided for the Options.
# install dependencies
npm install
# run test
npm test
# run test without pretest
npx jest
# run online example locally on http://localhost:3009/
npm run watch
MIT (c) Gastón Zalba.