Soumettre la recherche
Mettre en ligne
bsSelector.js(OctoberSky.js)
•
Télécharger en tant que PPTX, PDF
•
4 j'aime
•
1,768 vues
Seung-Hyun PAEK
Suivre
bsSelector Beyond the Sizzle.js. Fastest pure-JavaScript CSS DOM Selector engine.
Lire moins
Lire la suite
Logiciels
Signaler
Partager
Signaler
Partager
1 sur 53
Télécharger maintenant
Recommandé
bsSelector (OKJSP)
bsSelector (OKJSP)
Seung-Hyun PAEK
bsSelector (GDG DevFest 2014)
bsSelector (GDG DevFest 2014)
Seung-Hyun PAEK
KPW2012::LT::spot
KPW2012::LT::spot
도성 최
무료강의 논리적글쓰기 요약본
무료강의 논리적글쓰기 요약본
James (SeokHun) Hwang
마당발 경영
마당발 경영
A-type Company
에버노트 유저 컨퍼런스 - 이다희
에버노트 유저 컨퍼런스 - 이다희
Gina J Kim
글쓰기는 디자인이다. (글쓰기 워크숍 강의 자료.)
글쓰기는 디자인이다. (글쓰기 워크숍 강의 자료.)
Jae Yeon Kim
경영의교양을읽는다
경영의교양을읽는다
Yeounjoon Kim
Recommandé
bsSelector (OKJSP)
bsSelector (OKJSP)
Seung-Hyun PAEK
bsSelector (GDG DevFest 2014)
bsSelector (GDG DevFest 2014)
Seung-Hyun PAEK
KPW2012::LT::spot
KPW2012::LT::spot
도성 최
무료강의 논리적글쓰기 요약본
무료강의 논리적글쓰기 요약본
James (SeokHun) Hwang
마당발 경영
마당발 경영
A-type Company
에버노트 유저 컨퍼런스 - 이다희
에버노트 유저 컨퍼런스 - 이다희
Gina J Kim
글쓰기는 디자인이다. (글쓰기 워크숍 강의 자료.)
글쓰기는 디자인이다. (글쓰기 워크숍 강의 자료.)
Jae Yeon Kim
경영의교양을읽는다
경영의교양을읽는다
Yeounjoon Kim
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
Skeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
Introduction to Data Science
Introduction to Data Science
Christy Abraham Joy
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
Vit Horky
The six step guide to practical project management
The six step guide to practical project management
MindGenius
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
Contenu connexe
En vedette
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
Skeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
Introduction to Data Science
Introduction to Data Science
Christy Abraham Joy
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
Vit Horky
The six step guide to practical project management
The six step guide to practical project management
MindGenius
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
En vedette
(20)
2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
Skeleton Culture Code
Skeleton Culture Code
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Getting into the tech field. what next
Getting into the tech field. what next
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
How to have difficult conversations
How to have difficult conversations
Introduction to Data Science
Introduction to Data Science
Time Management & Productivity - Best Practices
Time Management & Productivity - Best Practices
The six step guide to practical project management
The six step guide to practical project management
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
bsSelector.js(OctoberSky.js)
1.
bsSelector.js
2.
PAEK, Seung-Hyun - projectBS
core committer - SHOU Communications
3.
projectBS
4.
projectBS bsJS
5.
bsJS var color =
bs.Dom('#domID') .S('border-radius', 5, '@width', 100, 'color', '#fff'); console.log(color) // "#fff“ var color = $('#domID').css({ 'borderRadius' : 5, 'WebkitBorderRadius' : 5, 'MozBorderRadius': 5 }) .attr('width', 100) .css('color'); console.log(color) // "#fff"
6.
7.
'bsJS 에 독자적인 셀렉터를
갖고싶은 데..'
8.
‘승현이 니가 만들 면
되겠네~!!'
9.
bsSelector
10.
Selector process query의 tokenizer 요소
선택 요소 순환 요소 판정 결과 반환
11.
Selector process query의 tokenizer 요소
선택 요소 순환 요소 판정 결과 반환
12.
Selector process query의 tokenizer 요소
선택 요소 순환 요소 판정 결과 반환
13.
Selector process query의 tokenizer 요소
선택 요소 순환 요소 판정 결과 반환
14.
Selector process query의 tokenizer 요소
선택 요소 순환 요소 판정 결과 반환
15.
Selector process query의 tokenizer 요소
선택 요소 순환 요소 판정 결과 반환
16.
query = 'ul.toc
li.tocline2‘; tokens = ['ul', '.toc', ' ', 'li', ‘.tocline2‘]; if(tokens[i].charAt(0) == '#') document.getElementById(query); else if(tokens[i].charAt(0) == '.') document.getElementByClassName(query); else document.getElementsByTagName('*');
17.
‘CSS2 spec 은
기본 아냐?'
18.
‘CSS3 spec 도
하는 김에 하지?'
19.
‘CSS4 spec 도 &^&&^%&%'
20.
일단 완성
21.
Sizzle speed
22.
23.
jsPerf.com
24.
getElementById getElementsByTagName getElementsByClassName getElementsByName querySelectorAll
25.
26.
27.
ID TAG CLASS
NAME 2,096,567 1,876,875 1,841,273 1,575,123 17,090,351 8,920,145 8,285,463 8,031,034 19,384,745 16,661,973 17,559,678 19,073,485
28.
29.
ID TAG CLASS 124,963
126,480 106,504 1,091,549 222,199 210,918 2,020,367 321,119 339,747
30.
상황은 조금 나아 졌지만… 다음은???
31.
JavaScript는 인터프리터 언어
32.
인터프리터?
33.
34.
함수 호출을 최소화
35.
함수 호출을 최소화
한다
36.
함수 호출을 최소화
한다 function Non function 16,830 54,080 49,063 49,436 51,524 52,066
37.
네이티브메서드 안심하지 말자
38.
네이티브메서드라고 안심하지 말자
39.
네이티브메서드라고 안심하지 말자 forEach
for() 300 879 658 2,851 142 4,229
40.
네이티브메서드라고 안심하지 말자
41.
네이티브메서드라고 안심하지 말자 Function.bind
obj.add() 39,188,564 79,601,156 658 2851 5,125,064 473,773,657
42.
LinkedList getElementsByTagName getElementsByClassName
43.
var els =
document.getElementByTagName(‘div’); console.log(els.length); var newEl = document.createElement(‘div’); document.body.appendChild(newEl); console.log(els.length);
44.
반복의 제거
45.
div P[0] P[1] P[2]
46.
element.childNodes; children.nodeType == 1; VS element.children
47.
이런 사실들과 알고리즘등을 고려하면서 재작성
48.
이런 사실들과 알고리즘등을 고려하면서 재작성
49.
Sizzle Mootools-slick bsSelector 함수개수
: 140 93 13 라인수 : 1,214 2,037 305 용량 : 60,335 37,935 13,485
50.
그 결과
51.
Chrome
52.
IE
53.
감사합니다. ProjectBS https://www.facebook.com/groups/bs5js/ github bsJS http://ligo.kr/i7 github bsSelector http://ligo.kr/o8
Notes de l'éditeur
http://jsperf.com/jsconf-id-class-name-tag
http://jsperf.com/jsconf-id-class-name-tag/2
http://jsperf.com/jsconf-function-vs-non-function
http://jsperf.com/jsconf-array-prototype-foreach
http://jsperf.com/jsconf-native-method-function-prototype-bind
Télécharger maintenant