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
Vue.js Single File Components++
Search
kazupon
April 28, 2017
Programming
1.8k
8
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Vue.js Single File Components++
meguro.es x gotanda.js #1
kazupon
April 28, 2017
More Decks by kazupon
See All by kazupon
プラグインで拡張される Context をtype-safe にする難しさと設計判断
kazupon
2
1k
Oxlint JS plugins
kazupon
1
1.4k
gunshi
kazupon
1
240
Nitro v3
kazupon
2
560
わたしのOSS活動
kazupon
3
630
Vapor Revolution
kazupon
3
4.2k
Vue.js最新動向
kazupon
3
1.6k
Vue 3.4
kazupon
13
4.9k
Vue & Vite Rustify
kazupon
4
2.5k
Other Decks in Programming
See All in Programming
言語を使う側から、作る側へ。 自作 Lisp で得た新たな気づき。
andpad
0
110
ローカルLLMでどこまでコードが書けるか -拡張版 / How much code can be written on a local LLM Extended
kishida
12
4.7k
AIキャラアプリkaiwaの低遅延音声通話基盤をどう作ったか - AWS Gravitonで支える低遅延・低コストAI Agent基盤
mogamit
0
170
はてなアカウント基盤 State of the Union
cockscomb
1
1.3k
Claude Opus 4.6以後の受託開発エンジニアの変化(Claude Code開発ノウハウ大公開スペシャルbyクラスメソッド)
iidatakuma
1
630
AI 輔助遺留系統現代化的經驗分享
jame2408
1
1.2k
SREの積み重ねがAI駆動開発のガードレールになった ― 7つの実践/SRE Guardrails The 7
tomoyakitaura
8
4.1k
過去最大のMCPアップデート! 2026-07-28 RC版の謎に迫る
licux
6
460
Contextとはなにか
chiroruxx
1
390
フィードバックで育てるAI開発
kotaminato
1
110
symfony/aiとlaravel/boost
77web
0
120
AI時代の仕事技芸論〜ソフトウェア開発で「遊ぶように働く」職人的熟達のすすめ(スクフェス仙台 2026バージョン)
kuranuki
0
620
Featured
See All Featured
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
310
Documentation Writing (for coders)
carmenintech
77
5.4k
What's in a price? How to price your products and services
michaelherold
247
13k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9.1k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
2
4.1k
SEO for Brand Visibility & Recognition
aleyda
0
4.6k
Testing 201, or: Great Expectations
jmmastey
46
8.2k
GraphQLの誤解/rethinking-graphql
sonatard
75
12k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.6k
How Software Deployment tools have changed in the past 20 years
geshan
0
34k
Transcript
Vue.js Single File Components++ Meguro.es x Gontanda.js #1 2017-04-28 @kazupon
Who are you ?
Vue.js Core Team member https://github.com/kazupon
Introduction
• All in one file Single File Components .vue <HTML>
{CSS} ({JS}) Scoped CSS CSS Modules ES2015 in template
• Alternative language implementation Single File Components .vue
Single File Components • Include from HTML/CSS/JS Files .vue <HTML>
{CSS} ({JS})
Provide official some tools .vue vue-loader rollup-plugin-vue vueify bundling bundling
({JS})
So, Very useful!
Released new feature !! • In vue-loader v10.2, it was
published https://github.com/vuejs/vue-loader/commit/7d3e005d56781e8e5e4ae8f90212f782e4b3a509
And from v11.3 later • It become available used in
components! https://github.com/vuejs/vue-loader/commit/11cec30eb3925a144e1d484357b13c501d5fb3f9
Exciting feature!!
Custom Blocks
What’s Custom Blocks ? • Block of Single File Components
that defined with User. <blog> - - - title - - - bla bla bla … bla bla bla … </blog>
Custom Blocks Use cases • Documentation • Localization • Unit
Testing • Example playground • … etc
Documentation .vue .vue .vue .md vue-loader extract
Localization .vue ⚙ plugin vue-loader bundling ({JS}) hello run
Unit Testing .vue vue-loader bundling ({JS}) ✅ test1 : OK
✅ test2 : OK ❌ test3 : NG run
Example Playground .vue vue-loader bundling ({JS}) run playground runtime ⚙
Custom Blocks Real World
Localization with vue-i18n https://kazupon.github.io/vue-i18n/en/sfc.html message: hello world !!
Blog with ream (example) http://unvue-custom-block.surge.sh
vue-play (be planning) https://github.com/vue-play/vue-play/issues/5
DEMO
How to use
configure webpack conf
Available in Components • you need a custom loader
configure custom loader
Reference • vue-loader documentation https://vue-loader.vuejs.org
Conclusion
Conclusion • You can extend the single file components with
custom blocks • Depending on your idea, you can make your single file components even more useful !
One more thing …
Vue.js community for Japanese • You can join via Vue.js
official site http://jp.vuejs.org
genba.fm #1 • 2017/05 GW later, speak about Vue.js https://genba.fm
Thanks!