brentnycum / BNHtmlPdfKit

Easily turn HTML data from an HTML string or URL into a PDF file on iOS
MIT License
270 stars 62 forks source link

Using multiple css files issue #22

Open ldt25290 opened 7 years ago

ldt25290 commented 7 years ago

In HTML file, I have imported 2 css files like below :

        <link href="style.css" rel="stylesheet" type="text/css" />
        <link href="bootstrap.css" rel="stylesheet" type="text/css" />

Currently, the exported pdf file has only css style of the bootstrap.css file.

However, I tried to add important! property for each item in style.css, the pdf could display css style of style.css file.

#myContent {
    background-color: lightblue !important;
    font-family: Helvetica Neue, sans-serif;
    color: red !important;
    padding: 20px;
}

Anyone has been able to generate pdf using multiple css file and without using !important property?