├── .eslintignore ├── .gitignore ├── .nojekyll ├── CNAME ├── LICENSE ├── README.md ├── babel.config.js ├── deploy.sh ├── package-lock.json ├── package.json ├── public ├── favicon.ico └── index.html └── src ├── App.vue ├── assets ├── buttons.js └── logo.png ├── components ├── JsonToGeojsonForm.vue └── LeafletMap.vue └── main.js /.eslintignore: -------------------------------------------------------------------------------- 1 | buttons.js -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | # local env files 6 | .env.local 7 | .env.*.local 8 | 9 | # Log files 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | 14 | # Editor directories and files 15 | .idea 16 | .vscode 17 | *.suo 18 | *.ntvs* 19 | *.njsproj 20 | *.sln 21 | *.sw* 22 | -------------------------------------------------------------------------------- /.nojekyll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gavinr/arcgis-json-to-geojson/07487b01a7bf75cd31d3c0488b41c23123595065/.nojekyll -------------------------------------------------------------------------------- /CNAME: -------------------------------------------------------------------------------- 1 | arcgisjson.togeojson.com -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Gavin Rehkemper 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ArcGIS JSON to GeoJSON 2 | ====================== 3 | 4 | Need to convert some ArcGIS JSON to GeoJSON? This is a simple page that helps you do that. 5 | 6 | [![screenshot](https://i.imgur.com/DYlsFNm.png)](http://arcgisjson.togeojson.com/) 7 | 8 | View the site: http://arcgisjson.togeojson.com/ 9 | 10 | Development: Installation 11 | -------- 12 | 13 | - `npm install` 14 | 15 | Credit 16 | ------ 17 | 18 | This is just a web page wrapper that gives you access to the tools in: 19 | 20 | * [@terraformer/arcgis](https://github.com/terraformer-js/terraformer/blob/master/packages/arcgis/README.md) (formerly [arcgis-to-geojson-utils](https://github.com/Esri/arcgis-to-geojson-utils) which have been moved to `@terraformer`) 21 | 22 | Built using [vue-cli version 3](https://cli.vuejs.org/). 23 | 24 | 25 | Feedback 26 | -------- 27 | 28 | File bug reports here on GitHub or contact [Gavin Rehkemper](http://github.com/gavinr) [(gavinrehkemper @ twitter)](http://twitter.com/gavinrehkemper) for anything else. 29 | -------------------------------------------------------------------------------- /babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | '@vue/app' 4 | ] 5 | } -------------------------------------------------------------------------------- /deploy.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env sh 2 | 3 | # abort on errors 4 | set -e 5 | 6 | # build 7 | npm run build 8 | 9 | # navigate into the build output directory 10 | cd dist 11 | 12 | # if you are deploying to a custom domain 13 | echo 'arcgisjson.togeojson.com' > CNAME 14 | 15 | git init 16 | git add -A 17 | git commit -m 'deploy' 18 | 19 | # if you are deploying to https://.github.io 20 | # git push -f git@github.com:/.github.io.git master 21 | 22 | # if you are deploying to https://.github.io/ 23 | git push -f https://github.com/gavinr/arcgis-json-to-geojson master:gh-pages 24 | 25 | cd - -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "arcgis-json-to-geojson", 3 | "description": "Convert ArcGIS JSON to GeoJSON", 4 | "version": "2.2.1", 5 | "author": "Gavin Rehkemper ", 6 | "license": "MIT", 7 | "private": true, 8 | "scripts": { 9 | "serve": "vue-cli-service serve", 10 | "build": "vue-cli-service build", 11 | "lint": "vue-cli-service lint" 12 | }, 13 | "dependencies": { 14 | "@terraformer/arcgis": "^2.0.7", 15 | "bootstrap": "^4.5.0", 16 | "esri-leaflet": "^2.4.1", 17 | "leaflet": "^1.6.0", 18 | "vue": "^2.6.11", 19 | "vue-clipboard2": "^0.3.1" 20 | }, 21 | "devDependencies": { 22 | "@vue/cli-plugin-babel": "^4.4.6", 23 | "@vue/cli-plugin-eslint": "^4.4.6", 24 | "@vue/cli-service": "^4.4.6", 25 | "@vue/eslint-config-prettier": "^6.0.0", 26 | "babel-eslint": "^10.1.0", 27 | "eslint": "^7.6.0", 28 | "eslint-plugin-vue": "^6.2.2", 29 | "node-sass": "^4.14.1", 30 | "sass-loader": "^9.0.2", 31 | "vue-template-compiler": "^2.6.11" 32 | }, 33 | "eslintConfig": { 34 | "root": true, 35 | "env": { 36 | "node": true 37 | }, 38 | "extends": [ 39 | "plugin:vue/essential", 40 | "eslint:recommended" 41 | ], 42 | "rules": {}, 43 | "parserOptions": { 44 | "parser": "babel-eslint" 45 | } 46 | }, 47 | "postcss": { 48 | "plugins": { 49 | "autoprefixer": {} 50 | } 51 | }, 52 | "browserslist": [ 53 | "> 1%", 54 | "last 2 versions", 55 | "not ie <= 8" 56 | ] 57 | } 58 | -------------------------------------------------------------------------------- /public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/gavinr/arcgis-json-to-geojson/07487b01a7bf75cd31d3c0488b41c23123595065/public/favicon.ico -------------------------------------------------------------------------------- /public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | Convert ArcGIS JSON to GeoJSON 9 | 10 | 11 | 12 | 13 | 14 | 15 | 18 |
19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /src/App.vue: -------------------------------------------------------------------------------- 1 | 57 | 58 | 86 | 87 | 104 | -------------------------------------------------------------------------------- /src/assets/buttons.js: -------------------------------------------------------------------------------- 1 | !function(){"use strict";var d,l,s,e,t,o,h=window.document,n=h.location,p=window.encodeURIComponent,c=window.decodeURIComponent,r=window.Math,u=function(e){return h.createElement(e)};l="github-button",d=(/^http:/.test(n)?"http":"https")+"://buttons.github.io",s="/buttons.html",e=function(e){d=e},t="currentScript",o=!{}.hasOwnProperty.call(h,t)&&h[t]&&delete h[t]&&h[t]?h[t].src:void 0;var f,g,a;f=function(e,t,o){e.addEventListener?e.addEventListener(""+t,o):e.attachEvent("on"+t,o)},g=function(t,o,n){var r;f(t,o,r=function(e){return t.removeEventListener?t.removeEventListener(""+o,r):t.detachEvent("on"+o,r),n(e)})},a=function(e){var t,o;/m/.test(h.readyState)||!/g/.test(h.readyState)&&!h.documentElement.doScroll?setTimeout(e):h.addEventListener?(o=0,g(h,"DOMContentLoaded",t=function(){!o&&(o=1)&&e()}),g(window,"load",t)):(t=function(){/m/.test(h.readyState)&&(h.detachEvent("onreadystatechange",t),e())},h.attachEvent("onreadystatechange",t))};var m,w,b,v,x,i,C,y,F,k,z="body{margin:0}a{color:#24292e;text-decoration:none;outline:0}.widget{display:inline-block;overflow:hidden;font-family:-apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif;font-size:0;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.btn,.social-count{display:inline-block;font-weight:600;vertical-align:bottom;cursor:pointer;border:1px solid #d1d2d3;border-radius:0.25em}.btn:focus,.social-count:focus{border-color:#c8e1ff}.btn{background-color:#eff3f6;background-image:-webkit-linear-gradient(top, #fafbfc, #e4ebf0);background-image:-moz-linear-gradient(top, #fafbfc, #e4ebf0);background-image:linear-gradient(to bottom, #fafbfc, #e4ebf0);background-repeat:repeat-x;background-size:110% 110%;-ms-filter:\"progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFFAFBFC', endColorstr='#FFE4EBF0')\";*filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFFAFBFC', endColorstr='#FFE4EBF0')}.btn:active{background-color:#e9ecef;background-image:none;border-color:#afb1b2;box-shadow:inset 0 0.15em 0.3em rgba(27,31,35,0.15)}.btn:hover{background-color:#e6ebf1;background-image:-webkit-linear-gradient(top, #f0f3f6, #dce3ec);background-image:-moz-linear-gradient(top, #f0f3f6, #dce3ec);background-image:linear-gradient(to bottom, #f0f3f6, #dce3ec);border-color:#afb1b2;-ms-filter:\"progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFF0F3F6', endColorstr='#FFDCE3EC')\";*filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFF0F3F6', endColorstr='#FFDCE3EC')}.social-count{position:relative;background-color:#fff}.social-count:hover{color:#0366d6}.octicon{position:relative;display:inline-block;vertical-align:top;fill:currentColor}.btn,.social-count{height:18px;padding:0 5px;line-height:18px}.btn{font-size:11px}.social-count{margin-left:5px;font-size:10px}.octicon{height:14px;top:2px}.large .btn,.large .social-count{height:26px;line-height:26px}.large .btn{padding:0 10px;font-size:12px}.large .social-count{padding:0 7px;margin-left:7px;font-size:11px}.large .octicon{height:18px;top:4px}.social-count b,.social-count i{position:absolute;top:50%;right:100%;display:block;width:0;height:0;margin-top:-4px;_font-size:0;_line-height:0;border:solid transparent;border-width:4px 4px 4px 0}.social-count b{margin-right:0;border-right-color:#d1d2d3}.social-count:focus b{border-right-color:#c8e1ff}.social-count i{margin-right:-1.5px;border-right-color:#fff}.social-count b,.social-count i{_border-top-color:red !important;_border-bottom-color:red !important;_border-left-color:red !important;_filter:chroma(color=red)}.large .social-count b,.large .social-count i{margin-top:-6px;border-width:6px 6px 6px 0}\n",E={"mark-github":{width:16,height:16,path:''},eye:{width:16,height:16,path:''},star:{width:14,height:16,path:''},"repo-forked":{width:10,height:16,path:''},"issue-opened":{width:14,height:16,path:''},"cloud-download":{width:16,height:16,path:''}};m=function(e,t){return e=(""+e).toLowerCase().replace(/^octicon-/,""),E.hasOwnProperty(e)||(e="mark-github"),'"},b={},w=function(e,t){var o,n,r,a,i,l,c,d;1<(l=b[e]||(b[e]=[])).push(t)||(a=0,n=function(){if(!a&&(a=1))for(delete b[e];t=l.shift();)t.apply(null,arguments)},(o=window.XMLHttpRequest)&&"withCredentials"in o.prototype?(d=new o,f(d,"abort",n),f(d,"error",n),f(d,"load",function(){n(200!==d.status,function(){try{return JSON.parse(d.responseText)}catch(e){}}())}),d.open("GET",e),d.send()):((r=this||window)._=function(e){r._=null,n(200!==e.meta.status,e.data)},(c=r.document.createElement("script")).async=!0,c.src=e+(/\?/.test(e)?"&":"?")+"callback=_",f(c,"error",i=function(){r._&&r._({meta:{}})}),c.readyState&&f(c,"readystatechange",function(){"loaded"===c.readyState&&i()}),r.document.getElementsByTagName("head")[0].appendChild(c)))},v=function(e,t,o){var r,a,n,i,l,c,d,s,h,p,u,f,g,b;t&&(n=this,c=e.ownerDocument,l=function(e){return c.createTextNode(e)},(d=(i=function(e){return c.createElement(e)})("style")).type="text/css",e.appendChild(d),d.styleSheet?d.styleSheet.cssText=z:d.appendChild(l(z)),(s=e.appendChild(i("div"))).className="widget"+(/^large$/i.test(t["data-size"])?" large":""),a=function(){o&&o(s)},(h=i("a")).href=t.href,h.target="_blank",/\.github\.com$/.test("."+h.hostname)?/^https?:\/\/((gist\.)?github\.com\/[^\/?#]+\/[^\/?#]+\/archive\/|github\.com\/[^\/?#]+\/[^\/?#]+\/releases\/download\/|codeload\.github\.com\/)/.test(h.href)&&(h.target="_top"):(h.href="#",h.target="_self"),h.className="btn",(p=t["aria-label"])&&h.setAttribute("aria-label",p),h.innerHTML=m(t["data-icon"],/^large$/i.test(t["data-size"])?16:14),h.appendChild(l(" ")),h.appendChild(i("span")).appendChild(l(t["data-text"]||"")),r=s.appendChild(h),/^(true|1)$/i.test(t["data-show-count"])&&"github.com"===r.hostname?!(g=r.pathname.replace(/^(?!\/)/,"/").match(/^\/([^\/?#]+)(?:\/([^\/?#]+)(?:\/(?:(subscription)|(fork)|(issues)|([^\/?#]+)))?)?(?:[\/?#]|$)/))||g[6]?a():(g[2]?(u="/repos/"+g[1]+"/"+g[2],g[3]?(b="subscribers_count",f="watchers"):g[4]?(b="forks_count",f="network"):g[5]?(b="open_issues_count",f="issues"):(b="stargazers_count",f="stargazers")):(u="/users/"+g[1],f=b="followers"),w.call(n,"https://api.github.com"+u,function(e,t){var o,n;e||(n=t[b],(o=i("a")).href=t.html_url+"/"+f,o.target="_blank",o.className="social-count",o.setAttribute("aria-label",n+" "+b.replace(/_count$/,"").replace("_"," ")+" on GitHub"),o.appendChild(i("b")),o.appendChild(i("i")),o.appendChild(i("span")).appendChild(c.createTextNode((""+n).replace(/\B(?=(\d{3})+(?!\d))/g,","))),r.parentNode.insertBefore(o,r.nextSibling)),a()})):a())},x=function(){var e,t,o,n,r,a,i;if(t=[],h.querySelectorAll)t=h.querySelectorAll("a."+l);else for(o=0,r=(i=h.getElementsByTagName("a")).length;o 2 |
3 |
4 | 10 |
11 | 12 |
13 | 20 |
21 | 22 |
23 |
24 | 31 |
32 |
33 | 34 |
35 | 41 |
42 | 43 |
44 |
45 | 48 | 57 |
58 |
59 |
60 | 61 | 62 | 150 | 151 | 156 | -------------------------------------------------------------------------------- /src/components/LeafletMap.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 119 | 120 | 121 | 130 | -------------------------------------------------------------------------------- /src/main.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import VueClipboard from 'vue-clipboard2' 3 | import App from './App.vue' 4 | 5 | Vue.use(VueClipboard); 6 | 7 | Vue.config.productionTip = false 8 | 9 | new Vue({ 10 | render: h => h(App) 11 | }).$mount('#app') 12 | --------------------------------------------------------------------------------