Skip to content

The following example shows how to use the preload option when using responsive design. This will load more than one style depends on the width of the screen.

Notifications You must be signed in to change notification settings

RedaAwwad/preload-with-responsive-design

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Preload with Responsive Design

The following example shows how to use the preload option when using responsive design. This will load more than one style depends on the width of the screen. In this example, there are two style files, one for the larage screens and the other on for the small screens (mobiles & tablets).

    <link
        rel="preload"
        href="assets/css/style.css"
        as="style"
        media="(min-width: 601px)"
    >
    <!--... -->
    <link
        rel="preload"
        href="assets/css/style.sm.css"
        as="style"
        media="(max-width: 600px)"
    >

About

The following example shows how to use the preload option when using responsive design. This will load more than one style depends on the width of the screen.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published