ST 6 Flashcards

1
Q

versatile scripting language primarily used for web development

A

javascript

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

It allows developers to add interactivity and dynamic behavior to web pages

A

javascript

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q
  • a client-side scripting language, running in the user’s web browser
  • widely supported by major web browsers, ensuring compatibility
  • can manipulate the Document Object Model (DOM) to modify web page content dynamically
A

javascript

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

JavaScript – When to use

A
  1. Client-side Web Development
  2. Web Applications
  3. UI Enhancement
  4. Form validation
  5. Web-based games and multimedia
  6. API Integration
  7. Data Visualization
  8. Server-side Development
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q
  • is primarily used for enhancing the interactivity and functionality of websites
  • create dynamic web pages, handle user input, perform form validation, and update content without requiring a page refresh
A

Client-side Web Development

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q
  • It allows you to create complex user interfaces, manage client-side routing, and communicate with servers via AJAX or Fetch API
  • essential for building web applications, including Single Page Applications (SPAs)
A

Web Applications

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q
  • improve the user experience by creating interactive elements like sliders, image carousels, accordions, and pop-up dialogs
  • real-time updates, such as live chat and notifications
A

User Interface (UI) Enhancement

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

commonly used to validate user input in web forms before submission. You can check for empty fields, validate email addresses, enforce password complexity rules, and provide instant feedback to users

A

Form validation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

be used to create web-based games, multimedia applications, and interactive animations. Libraries like Three.js and Phaser.js

A

Web-based games and multimedia

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q
  • can interact with various Web APIs, including geolocation, device orientation, and Web Bluetooth.
  • This allows you to build location-aware apps, access device sensors, and integrate with hardware peripherals
A

Web APIs Integration

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q
  • enable the creation of interactive data visualizations and charts on web pages
  • particularly useful for displaying data-driven insights
  • D3.js and Chart.js
A

Data Visualization

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
  • you can use JavaScript for server-side development, creating web servers, APIs, and real-time applications
  • useful for building full-stack applications
A

Server-Side Development

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Arithmetic with JavaScript

A

// Addition
var resultAdd = 5 + 3;
console.log(“5 + 3 =”, resultAdd);

// Subtraction
var resultSubtract = 10 - 4;
console.log(“10 - 4 =”, resultSubtract);

// Multiplication
var resultMultiply = 6 * 7;
console.log(“6 * 7 =”, resultMultiply);

// Division
var resultDivide = 20 / 5;
console.log(“20 / 5 =”, resultDivide);

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q
  • offers a vast ecosystem of plugins and extensions created by the community, which enhances its functionality.
  • These plugins cover everything from form validation to creating interactive UI components and animations, making development more efficient
A

Rich Set of Plugins

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

simplifies event handling by providing methods to attach and detach event handlers. This makes it straightforward to respond to user interactions like clicks, keypresses, and mouse movements

A

Event Handling

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

One of jQuery’s primary strengths is its ability to easily manipulate the Document Object Model (DOM) of a web page. Developers can select, traverse, modify, and manipulate HTML elements with ease.

A

DOM Manipulation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

abstracts browser-specific differences and provides a consistent API, making it easier to develop web applications that work seamlessly across different web browsers

A

Cross-Browser Compatibility

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

a fast, concise, and widely used JavaScript library that simplifies the process of working with HTML documents, handling events, and performing animations.

A

JavaScript Library

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

is like a microwave – it can quickly heat up your leftovers (pre-written functions) with just a push of a button. It’s fast and convenient but won’t impress the food critics (developers) as much

A

jQuery

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

like a chef who can cook up a gourmet meal from scratch, but sometimes you have to spend hours chopping vegetables and sweating over a hot stove (writing code).

A

JavaScript

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Include jQuery in Your HTML File

A

include

  just before the closing </body> tag to ensure that the jQuery code is executed after the DOM has loaded.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

Selects HTML elements based on CSS-style selectors

A

$(selector):

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

Wraps a DOM element with a jQuery object for further manipulation

A

$(element):

24
Q

Selects all elements on the page

A

$(“*”)

25
Selecting Elements
1. $selector 2. $element 3. $("*")
26
Removes elements from the DOM
.remove():
27
Inserts content before an element.
.before():
28
Inserts content after an element
.after():
29
Inserts content at the beginning of an element.
.prepend():
30
Inserts content at the end of an element
.append():
31
Gets or sets the text content of an element
.text():
32
Gets or sets the HTML content of an element
.html():
33
DOM Manipulation Functionalities and Methods
1. .html() 2. .text() 3. .append() 4. .prepend() 5. .after() 6. .before() 7. .remove()
34
Gets or sets CSS properties of elements
.css():
35
Removes one or more classes from elements.
.removeClass():
36
Adds one or more classes to elements
.addClass():
37
CSS Manipuation Methods
1. .addClass() 2. removeClass() 3. .css()
38
Removes event handlers from elements
off():
39
Attaches one or more event handlers to elements
.on()
40
Attaches a click event handler to elements
.click()
41
Event Handling Methods
1. .click() 2. .on() 3. .off()
42
Displays hidden elements with an animation
.show():
43
Hides elements with an animation
.hide():
44
Fades in elements
.fadeIn()
45
Fades out elements
.fadeOut()
46
Animation Method
1. .show() 2. .hide() 3. .fadeIn() 4. fadeOut()
47
Merges the contents of two or more objects together.
$.extend():
48
Iterates over elements or objects
$.each():
49
Utility Functions Methods
1. $.each() 2. $.extend()
50
Gets or sets properties of elements
prop():
51
Gets or sets attributes of elements.
.attr():
52
Attribute Manipulation Method
1. .attr() 2. .prop()
53
Finds elements matching a selector within a selection
.find()
54
Gets the child elements
.children()
55
Gets the parent element
.parent()
56