Javatpoint Logo
Javatpoint Logo

Less data-uri()

The Less Data-uri function is uniform resource identifier (URI) schema which is used to inline a resource in web pages. The Node uses mime package to determine the correct mine type, if the mime type is not given.

Parameter:

? url: Inline the url of the file.

? mimetype: MIME type string. (optional)

Let's take an example to demonstrate the usage of Data-uri function in the Less file.

Create a HTML file named "simple.html", having the following data.

HTML file: simple.html

Less file: simple.less

Put the both file ?simple.html? and ?simple.less? inside the root folder of Node.js

Now, execute the following code: lessc simple.less simple.css

Less data uri function1

Output:

Less data uri function2



Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA