Socket
Socket
Sign inDemoInstall

w3wconverter

Package Overview
Dependencies
95
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

w3wconverter

Coverts postcodes to lat-long coordinates via Google Places API, then into What3Words addresses.


Version published
Maintainers
1
Weekly downloads
11
increased by1000%

Weekly downloads

Readme

Source

What3Words Converter

Need to convert postcodes into What3Words addresses? W3WConverter uses Google Places API to convert a postcode into latitude-longitude coordinates and then sends these to What3Words via their API to output a CSV file containing What3Words addresses.

Config

You will need to create a .env file and set the following variables with your own API keys: GOOGLE_API_KEY and W3W_API_KEY.

Installation

npm install w3wconverter
const W3WConverter = require('w3wconverter');
...
const config = [];
config['fileToConvert'] = <path to file>;
config['fileToWrite'] = <filename without extension>;
config['postcode'] =  <supplied single postcode from JSON>;
const w3wconverter = new W3WConverter(config);

// Returns a Json type response that can be displayed in a webpage. Console also shows 'Done'
const result = w3wconverter.convertData(); 

License

GNU General Public License v3.0

Keywords

FAQs

Last updated on 21 Oct 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc