URL Modifications
To modify the value of the URLs that are represented by the object, we can simply add new values for them. For instance, from the below URL, we will modify the username and password, which will update the overall URL. Thus, the properties of the URL can be settable.
Syntax
// Changes the username and password attribute of the URL component.
let name = "geeks1";
let pswd = 'geek@123';
let url = new URL("https://w3wiki.com/login");
url.username = name;
url.password = pswd;
Web API URL
The Web API URL is used to access and manipulate URLs. URL stands for Uniform Resource Locator. A URL is a unique address which is pointing to the resource. The URL is essential for making HTTP requests for making interactions with the API and for getting or sending data.
Table of Content
- Concepts and Usage
- Accessing components of URL
- URL Modifications
- Implementing the Queries
We will explore the above topics with their description and understand them with suitable examples.