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
Hack your Nuxt router!
Search
andoshin11
December 11, 2019
Technology
1.4k
0
Share
Hack your Nuxt router!
Enhance your Nuxt application by extracting the router object and hacking it!
Here's how.
andoshin11
December 11, 2019
More Decks by andoshin11
See All by andoshin11
Introduction to gRPC Interceptors
andoshin11
0
100
カーナベルにおけるProtobuf二次利用例
andoshin11
0
170
Envoy External AuthZとgRPC Extensionを利用した「頑張らない」Microservices認証認可基盤
andoshin11
0
950
カーナベル株式会社2024年2月 エンジニアイベント資料
andoshin11
0
520
Private Cloudを支える最高のユーザーガイド運用技術
andoshin11
0
320
TS CompilerがVueを喋れても良いじゃないか
andoshin11
0
790
ain't giving up type-safe Express
andoshin11
2
490
Type Safe "Everything"
andoshin11
0
290
GatewayパターンとSchema駆動開発
andoshin11
7
1.6k
Other Decks in Technology
See All in Technology
生成AIはソフトウェア開発の革命か、ソフトウェア工学の宿題再提出なのか -ソフトウェア品質特性の追加提案-
kyonmm
PRO
2
870
PdM・Eng・QAで進めるAI駆動開発の現在地/aidd-with-pdm-eng-qa
shota_kusaba
0
170
AI時代の品質はテストプロセスの作り直し #scrumniigata
kyonmm
PRO
4
1.4k
Agent の「自由」と「安全」〜未来に向けて今できること〜
katayan
0
350
Oracle Cloud Infrastructure presents managed, serverless MCP Servers for Oracle AI Database
thatjeffsmith
0
220
20260507-ACL-seminar
satoshi5884
0
110
新卒エンジニア研修、ハンズオンの設計における課題と実践知/ #tachikawaany
nishiuma
2
140
Every Conversation Counts
kawaguti
PRO
0
200
SREの仕事は「壊さないこと」ではなくなった 〜自律化していくシステムに、責任と判断を与えるという価値〜 / 20260515 Naoki Shimada
shift_evolve
PRO
1
110
ServiceによるKubernetes通信制御ーClusterIPを例に
miku01
1
160
生成AI時代に信頼性をどう保ち続けるか - Policy as Code の実践
akitok_
1
190
エンタープライズの厳格な制約を開発者に意識させない:クラウドネイティブ開発基盤設計/cloudnative-kaigi-golden-path
mhrtech
0
380
Featured
See All Featured
The SEO Collaboration Effect
kristinabergwall1
1
440
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
280
End of SEO as We Know It (SMX Advanced Version)
ipullrank
3
4.2k
Practical Orchestrator
shlominoach
191
11k
What does AI have to do with Human Rights?
axbom
PRO
1
2.1k
Into the Great Unknown - MozCon
thekraken
41
2.5k
Gemini Prompt Engineering: Practical Techniques for Tangible AI Outcomes
mfonobong
2
390
Site-Speed That Sticks
csswizardry
13
1.2k
A Tale of Four Properties
chriscoyier
163
24k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
Building Adaptive Systems
keathley
44
3k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.2k
Transcript
Hack your Nuxt router! @andoshin11 Sample Code :https://github.com/andoshin11/studio-andy/pull/119
Routing in Nuxt.js • Place a file inside the pages
directory • Instantly becomes a new route • Incredibly simple and easy! • However...
By extracting router object • Easier to overlook route-meta •
Easier to type-check • Easier to make a url-builder • Easier to generate breadcrumbs
Using router module @nuxtjs/router
Quick Setup! • Install router-module
Quick Setup! • Install router-module • Register the module
Quick Setup! • Install router-module • Register the module •
Create router file
Tips: migrate from default router Step 1 $ nuxt build
Step 2 router.js will be generated Step 3 Copy and paste contents
Override RouteMeta type def
Making url-builder (preparation) • First we need a route resolver
to retrieve the entire ancestors
Making url-builder
Generate Breadcrumbs
Generate Breadcrumbs
Generate Breadcrumbs
Generate Breadcrumbs
Thank you!