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
Web Components with Vue.js 2018
Search
takanorip
July 30, 2018
Technology
0
220
Web Components with Vue.js 2018
takanorip
July 30, 2018
Tweet
Share
More Decks by takanorip
See All by takanorip
Design System Documentation Tooling 2025
takanorip
3
2.3k
デザインエンジニアの延長にデザインマネージャーとしての可能性を探る
takanorip
1
900
Tools for Design Engineers other than LLM in the LLM era
takanorip
1
650
Bulletproof Design System with TypeScript
takanorip
7
4.7k
Eleventy3.0 で始める爆速個人ブログ開発!
takanorip
0
250
Webフォント選定の極意!フォントの基本から最新トレンドまで徹底解説
takanorip
5
1k
効果的な管理画面を デザインをするために 避けるべき5つの罠
takanorip
15
7.7k
社内管理画面のデザインもプロダクトデザイン
takanorip
5
2.2k
早わかり W3C Community Group
takanorip
0
550
Other Decks in Technology
See All in Technology
Ruby版 JSXのRuxが気になる
sansantech
PRO
0
160
Kiro IDEのドキュメントを全部読んだので地味だけどちょっと嬉しい機能を紹介する
khmoryz
0
200
SREのプラクティスを用いた3領域同時 マネジメントへの挑戦 〜SRE・情シス・セキュリティを統合した チーム運営術〜
coconala_engineer
2
670
小さく始めるBCP ― 多プロダクト環境で始める最初の一歩
kekke_n
1
450
15 years with Rails and DDD (AI Edition)
andrzejkrzywda
0
200
生成AIを活用した音声文字起こしシステムの2つの構築パターンについて
miu_crescent
PRO
3
210
SREが向き合う大規模リアーキテクチャ 〜信頼性とアジリティの両立〜
zepprix
0
460
GitHub Issue Templates + Coding Agentで簡単みんなでIaC/Easy IaC for Everyone with GitHub Issue Templates + Coding Agent
aeonpeople
1
250
コスト削減から「セキュリティと利便性」を担うプラットフォームへ
sansantech
PRO
3
1.5k
ランサムウェア対策としてのpnpm導入のススメ
ishikawa_satoru
0
190
広告の効果検証を題材にした因果推論の精度検証について
zozotech
PRO
0
190
ファインディの横断SREがTakumi byGMOと取り組む、セキュリティと開発スピードの両立
rvirus0817
1
1.5k
Featured
See All Featured
The SEO identity crisis: Don't let AI make you average
varn
0
290
Information Architects: The Missing Link in Design Systems
soysaucechin
0
780
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Being A Developer After 40
akosma
91
590k
Tips & Tricks on How to Get Your First Job In Tech
honzajavorek
0
440
Designing Powerful Visuals for Engaging Learning
tmiket
0
240
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
34
2.6k
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.3k
Designing for Performance
lara
610
70k
Mozcon NYC 2025: Stop Losing SEO Traffic
samtorres
0
140
Mobile First: as difficult as doing things right
swwweet
225
10k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
76
Transcript
Web Components with Vue.js 2018 Takanori OKi @Vue.js Night Nagoya
Self Introduction • Takanori Oki ( @takanorip ) • SmartDrive
Inc. Frontend Developer based in Tokyo • Nuxt.js, React, Polymer, etc… • Polymer Japan Translation team • I have published a book recently !
None
None
What are Web Components?
What are Web Components? Web components are a set of
web platform APIs that allow you to create new custom, reusable, encapsulated HTML tags to use in web pages and web apps. by webcomponents.org
Feature of Web Components • Based on existing web standards
• Can make components that is encapsulated styling • Can Use with any JavaScript Frameworks
What are Web Components? • Custom Elements • Shadow DOM
• HTML Imports (deprecated) → Under Discussion (ES Modules / HTML Modules?) • HTML Templates
Browser support Chrome Safari Firefox Edge HTML Templates STABLE STABLE
STABLE STABLE Custom Elements STABLE STABLE DEVELOPING CONSIDERING Shadow DOM STABLE STABLE DEVELOPING CONSIDERING ES Modules STABLE STABLE STABLE STABLE HTML Imports STABLE POLYFILL POLYFILL POLYFILL
Web Components with Vue.js
We want to use same custom components between different JavaScript
Frameworks !!! (React, Vue, Angular…)
How use Web Components?
lit-html https://github.com/Polymer/lit-html
What is lit-html? • JavaScript template literals + HTML templates
• Extremely fast • Give you the full power of JavaScript and functional programming patterns • Extremely customizable and extensible
None
None
None
lit-extended • lit-html is a library for handling HTML •
So it can pass values to component as String only • lit-extended is a solution of this demerit
Create Web Components with Vue CLI 3
vue-web-component-wrapper • Wrap and register a Vue component as a
custom element • Use Vue Components in Other JS Frameworks (React, Angular…) as a Web Components • Not affected by external CSS
None
Building • Use “vue-cli-service build” command • Produce a production-ready
bundle with minification for JS/CSS/HTML • Also Use “—target wc” option • Create a bundle for building a web component
None
THANK YOU ! ( Font : Vegur)