Giter VIP home page Giter VIP logo

nopcommerce.htmloptimiser's People

Contributors

tomvanenckevort avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

nopcommerce.htmloptimiser's Issues

Upgrade plugin to work with NopCommerce 3.8

Are there any plans to upgrade the plugin for the newer version of NopCommerce? Current version of plugin doesn't seem to work with NopCommerce 3.8.

Can you please tell me if I'm doing smth wrong or should some changes be made to the plugin? Thank you!

Add minification options

The WebMarkupMin library is currently set to minify everything (remove comments, quotes, etc.).
All these options can be configured as well, and therefore it would be good to have configuration options in the plugin screen where users can set which minification options they would like to use.

Minification breaks HTML layout

Reported by a user: in certain cases the minification concatenates the HTML attribute to the tag, breaking the overall page layout.

Example:

<div
      id="test"></div>

gets minified to:

<divid="test"></div>

Intermittent stream IndexOutOfRangeExcception error

An intermittent error that appears in the logs was reported by a user:

System.IndexOutOfRangeException: Probable I/O race condition detected while copying memory. 
The I/O package is not thread safe by default. In multithreaded applications, a stream 
must be accessed in a thread-safe way, such as a thread-safe wrapper returned by 
TextReader's or TextWriter's Synchronized methods. This also applies to classes like 
StreamWriter and StreamReader. at System.Buffer.InternalBlockCopy(Array src, Int32 
srcOffsetBytes, Array dst, Int32 dstOffsetBytes, Int32 byteCount) at 
System.IO.MemoryStream.ToArray() at Nop.Plugin.Misc.HtmlOptimiser.Code.WhitespaceFilter.Flush()

Invalid XML gets generated

Reported by a user: the HTML minification also gets applied to XML output (for example the sitemap) and strips out too many characters (mainly quotes) which causes the XML to be invalid:

<urlset xmlns=http://www.sitemaps.org/schemas/sitemap/0.9 
  xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance 
  xsi:schemalocation=http://www.sitemaps.org/schemas/sitemap/0.9 
  http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd>
  <url>
    <loc>http://localhost:15536/</loc>
    <changefreq>weekly</changefreq>
    <lastmod>2014-08-17</lastmod>
  </url>  
</urlset>

Unicode characters don't display correctly

Reported by a user: when using Unicode characters (like letters with accents) it displays them as a '?'.

Most probably because the stream filter uses the system default encoding type, which might be ASCII. Should force it to UTF-8 instead.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.