Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
OpenLayers ext TypeScript declarationの開発
Search
Taro Matsuzawa aka. btm
April 09, 2022
Programming
0
550
OpenLayers ext TypeScript declarationの開発
KoedoLUG 2022/04/09
Taro Matsuzawa aka. btm
April 09, 2022
Tweet
Share
More Decks by Taro Matsuzawa aka. btm
See All by Taro Matsuzawa aka. btm
平成生まれのためのUNIX&IT歴 史講座 ~番外編~
smellman
2
500
掛川城の点群データをiTownsで表示しよう
smellman
0
280
そのJavascript、全部TypeScriptにしちゃえ
smellman
1
210
大容量SSDとOpenStreetMap
smellman
0
130
MapLibreとtile.openstretmap.jpで始めるベクトル地図プログラミング
smellman
1
570
国内向けタイルサーバの構築と運用について
smellman
0
1.3k
Python/Javascriptで読む点群
smellman
1
5k
日本のCommunity向け タイルサーバの現状
smellman
0
2.7k
Pythonで点群を読んでみよう
smellman
1
2.5k
Other Decks in Programming
See All in Programming
カオスに立ち向かう小規模チームの装備の選択〜フルスタックTSという装備の強み _ 弱み〜/Choosing equipment for a small team facing chaos ~ Strengths and weaknesses of full-stack TS~
bitkey
1
150
iOSアプリで測る!名古屋駅までの 方向と距離
ryunakayama
0
160
In geheimer Mission: AI Agents entwickeln
joergneumann
0
120
Jakarta EE Meets AI
ivargrimstad
0
950
Cursorを活用したAIプログラミングについて 入門
rect
0
230
複雑なフォームの jotai 設計 / Designing jotai(state) for Complex Forms #layerx_frontend
izumin5210
6
1.6k
リアーキテクチャの現場で向き合う 既存サービスの読み解きと設計判断
ymiyamu
0
130
医療系ソフトウェアのAI駆動開発
koukimiura
1
120
LRパーサーはいいぞ
ydah
7
1.4k
ドメイン駆動設計とXPで支える子どもの未来 / Domain-Driven Design and XP Supporting Children's Future
nrslib
0
300
Global Azure 2025 @ Kansai / Hyperlight
kosmosebi
0
150
Boost Your Performance and Developer Productivity with Jakarta EE 11
ivargrimstad
0
920
Featured
See All Featured
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
34
2.2k
Building Adaptive Systems
keathley
41
2.5k
How GitHub (no longer) Works
holman
314
140k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
160
15k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
60k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
24
2.7k
GraphQLとの向き合い方2022年版
quramy
46
14k
Build The Right Thing And Hit Your Dates
maggiecrowley
35
2.7k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
331
21k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
41
2.3k
The Cult of Friendly URLs
andyhume
78
6.4k
Making the Leap to Tech Lead
cromwellryan
133
9.3k
Transcript
2022/04/09 1 OpenLayers ext TypeScript declarationの開発 Taro Matsuzawa @smellman KoedoLUG
2022/04/09
2022/04/09 2 自己紹介 • Georepublic Japan シニアデベロッパー兼CISO • 日本UNIXユーザ会会長 •
OSGeo.JP理事 • OpenStreetMap Foundation Japan メンバー • Breakcoreクラスタ • 最近のお気に入りはSynthamesk
2022/04/09 3 TypeScript declarationとは • 既存のJavaScriptライブラリに追加で型情報などを付与する仕組 み • よく yarn
install –dev @types/hogehoge などとして追加 • 型情報があるとコンパイル時にエラーなどを検出される • プログラムの安全性が増す
2022/04/09 4 OpenLayers extとは • https://github.com/Viglino/ol-ext • OpenLayersにいろいろな機能を追加するプラグイン • http://viglino.github.io/ol-ext/
• デモを見ると何ができるかわかる • 仕事上ではフォントアイコンを使いたい
2022/04/09 5 types-ol-ext • OpenLayers extにTypeScriptの定義を追加するためのdeclaration • OpenLayers 6.5.xまで対応 •
OpenLayers 6.14.1には対応されていない • types-ol パッケージに依存 • OpenLayers自体がTypeScript declarationを提供しているため不要のは ず • とりあえず改修をしてみているという話
2022/04/09 6 何をしているのか? • https://github.com/Siedlerchr/types-ol-ext/pull/84 • types-olの依存性を削除、OpenLayersの持つdeclarationを利用 • この段階で500件以上のエラー •
on/once/unイベントの型を改修 • examplesの中身も改修
2022/04/09 7 今のところいい感じです
2022/04/09 8 残タスク • types-ol-ext自体がまだ未実装のイベントがいくつかある • ol-extの実装を読みながら未実装の部分を追加する • examplesでまだ20件ほどのエラー •
だいたいはイベントの未実装部分なので実装をする • OpenLayers自体を拡張している部分があるのでどう対応するか… • examples自体を改修する • 来週いっぱいには修正を終わらせたい