)Z9 (0 LSKAPI M NTHaI - html5exam.jp · DOMContentLoaded HTML + - " load !,( + ' " The HTML5 Logo...

50
The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/ © LPI-Japan / EDUCO all rights reserved. )"Z?C!9 (0LSKA)&PI4A<FI 5M4 N#TH@HGa(2I 00*%-%S'BE9: K>LJ121) 5 U;

Transcript of )Z9 (0 LSKAPI M NTHaI - html5exam.jp · DOMContentLoaded HTML + - " load !,( + ' " The HTML5 Logo...

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.

) Z 9(0 LSKA PI

M N TH a I

00 S 121 ) 5

U

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.2

• -�0*��������ᵒ NTT����� #$��

ᵒ ���1,2 !��

• ���1%(���/.

• 2�&'���VR"��,

�+1)

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.3

HTML5�������� �#$���1 �� ��&��!

&��1���

Ver2.0�"%���������

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.4

• *+.-�('

• JavaScript API/%

• ),API�*�� �ᵒ � ������������API�Video, Canvas�

ᵒ ����"��!��API�Web Storage�

$#�&���

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.5

�������

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.6

• JavaScript API�)6���JavaScript�#'!&$(!�)6/

• API�9�����.���

• ,+�API�4�#'!&$(!�17���)6/

• ���-0�4�����API������ %�" ������3����������:�������*2� �����

58<;

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.7

JavaScript API�� ���������

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.8

• Web!���3.1�-;����%��=2��� &�$"'�/4ᵒ ,�Web�$��(�+2�

• ECMAScript��76*����):�0>�JavaScript�8�

• ES5�ES6�ES2018� �ECMAScript�<+���#'59

JavaScript��

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.9

• ���� #!*� ��

• ���%)

• ��������"��&0,'�.-

• +2(������!*/"

• �������%)

���JavaScript$1

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.10

• script����������

�����JavaScript�� ��1�

/

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.11

• script�"�src$����� �����������#�

������JavaScript!����2�

- / < . - /! . =. - / .- .". - /! . ". - /

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.12

• Application Programming Interface�*

• ������� �&������!(������#'�%"������)�%"������"$�����

API �

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.13

• Web47$(�AN�*,#8�OF JavaScript��PQ�E?������Web47$(;�?B�� ��

• CK��AN�*,#8�OF�������58-60"!':/:.�OF�02#*��!&+*�=D�%37#:<�*19�)OF��� @G���API�Web47$(�>M�����ᵒ ���J�IL�H������

JavaScript API��

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.14

• CodePen�2'ᵒ Web�!��$�HTML/CSS/JavaScript�1��4��������

ᵒ 9�� ��[Create]→[Pen]�%5/*

ᵒ ���1� ��-3�(0����

ᵒ ;)�,�������4.�:+

#"�6&87

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.15

Videovideo�����

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.16

• video"2� -�*�.+

• ���*�������������&�'��������3)��

• JavaScript API�,���&�'������%$��#1.+

• -�*�/0( ���*���� )�!(.+

video"2�3)

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.17

• https://codepen.io/suzukima/pen/qmzRby

• [�]������[�]�����

��

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.18

HTML

% 1 / 1 0 - - => %" 1 /% 1 - - /% < / - < %"% < / - / %"%" 1

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.19

• "var���"����ᵒ let � const������ ��var���

• ���������� ���������

��

L . B ,; . ;. = . ., E. ,; . ;. = . ., .

= ( . ) . . , , " /; , B L . S

. =

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.20

• �����������API��

• "document.querySelector(��)"��������������

�����

. E L . S. ,; . ;. = . ., .

= ( . ) . . , , " /; , B L . E

. =

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.21

• � �����API��

• “������.addEventListener()”�������������� ����������������

� ����

) B L E B . ) ) , (. , , . / " .

. , ) ;

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.22

���� �click ���������mouseenter ���������*�����mouseleave ���������*� %����focus �*�����������keydown ���&�����keyup ���%�����change input(�$�#)�����DOMContentLoaded HTML�+���� -�"�����load !,(�+����'�"�����

�������

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.23

• ����video�����API�

video��

B) ) , (. , , . / " .

) . , )

;

E B) , ) , (. , , . / " .

) , E. , ) ,

;

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.24

• ���������

• ��������� | MDN

• HTMLMediaElement | MDN

video��������

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.25

Web Storage���������� �

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.26

• �!�������$-�'%�� ����API

• ������ ,� ��$-���ᵒ +�����")""��,�"/(0."

• �����&#�$-���*���

Web Storage API

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.27

• https://codepen.io/suzukima/pen/QvXvZw

• �����������

• ���������������

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.28

HTML

" "

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.29

• "document.getElementsByTagName(� �)"����� ���

• !���������1 ����������[0]� ��

� ������

. 0 =; . 0 ( 0 / ( ' ) . 0

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.30

• 2,-���� ����� ��(���%"��/$ᵒ localStorage������0�#�������)����

ᵒ sessionStorage������#����!�*�����)����('.&�+�)

�� ���/$

/

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.31

• "�����.setItem(��, �)"������������������

• �� ���bgcolor����

������������

; ( ) .' / ( ) . , '.

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.32

• "����� ��������.value"��� ��������������

� ������

P I E C E L. , ,//( ; . , = .

P I/ ( ; ,. = /' ; , =P I .

; , ; ) . ; , =

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.33

• "if(��) { �� �� }"������ ���� ��������

������ ���������

'. ./) ./ ( ( ( '. ./

'. ./ I

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.34

• "�����.getItem(��)"��������� ���������

���������� ��

( ). ./ ;'/ ). ./ ./' ( ). ./

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.35

• "����� .style.������"� ������������������ ���������

�������

; / --. - / - -

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.36

• "������.value"����� �����������������

���������

; / . = =

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.37

• ���������ᵒ Web Storage API �� � | MDN

Web Storage����

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.38

Canvas���������

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.39

• canvas"/� *��JavaScript�-,���1'

• '0�������,(

• ����������1'�+%.)�!'�� ����#$���&�

Canvas

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.40

• https://codepen.io/suzukima/pen/owxNMg

• ������

��

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.41

HTML

" "

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.42

• "����canvas��.getContext('2d')"���������������� ������

���������

2 ;CE2 .2 "/. ) . .2 2

B= ;CE2 "/. ( 2 .

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.43

• "����.beginPath()"��������� ���

��� ���

/. ()

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.44

• “������.moveTo("!)”������"!������ᵒ "!������� ��(0,0)��

• "������.lineTo("!)"���"!� ����"!�����������

���#�

;13 .02 )0 (

13 ,/ )0 (

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.45

• "� ��.closePath()"���������

• "� ��.stroke()"������

�������

./ .(

./ . )

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.46

• ��������ᵒ canvas ��� ��� | MDN

Canvas����

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.47

����

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.48

• level1�+/).,0)�5A8����I'����(-�*�%��"�

• CodePen�!��4G�? #EC��#����$&97��>���?���#������ᵒ �����@D3����6��

• Mozilla Developer Network �12B�;<:F���=H

��$�J����� �

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.49

• 7,������

• &%1������2�������+��������4��"# ��ᵒ "#������0 3

• -/!.�������������2� �)�'�

• 7,������

-/�(��*�$���

The HTML5 Logo is licensed under Creative Commons Attribution 3.0. Unported by the W3C; http://creativecommons.org/licenses/by/3.0/

© LPI-Japan / EDUCO all rights reserved.50

Open the Future with HTML5.

@. -