官术网_书友最值得收藏!

Optimizing geographic data files with TopoJSON

The topojson is a command-line utility used to create files in the TopoJSON-serialized format. The TopoJSON format will be discussed in detail in Chapter 6, Finding and Working with Geographic Data. The topojson utility is also installed via npm.

Note

Note that we will use the syntax TopoJSON to refer to the JSON format and topojson to indicate the command-line utility.

We already have installed Node.JS and npm, so enter the following on the command line:

npm install -g topojson

Once the installation is complete, you should check the version of topojson installed on your machine just as we did with Node.js:

topojson –version

If you see Version 1.x, it means you have successfully installed topojson.

Tip

topojson uses node-gyp that has several dependencies based on the operating system. Please go to http://github.com/TooTallNate/node-gyp for details.

If you're using Windows, the basic steps are as follows:

  • Install Python 2.x (3.x not supported at the time of writing this book)
  • Install Microsoft Visual Studio C++ 2012 for Desktop (Express)
主站蜘蛛池模板: 麻栗坡县| 高平市| 斗六市| 齐河县| 屏南县| 类乌齐县| 镇雄县| 定远县| 中西区| 盈江县| 兴山县| 北辰区| 云浮市| 新乡市| 册亨县| 佛冈县| 泾川县| 桃园县| 淳化县| 兴业县| 台东市| 兴海县| 蚌埠市| 禄劝| 汨罗市| 阿拉善左旗| 清水河县| 青浦区| 永宁县| 济宁市| 克山县| 玛多县| 柯坪县| 乌审旗| 许昌市| 牟定县| 高尔夫| 彩票| 塔城市| 肥城市| 台前县|