Sponsored Content
Full Discussion: Optimizing JS and CSS
Top Forums Web Development Optimizing JS and CSS Post 303030912 by Akshay Hegde on Tuesday 19th of February 2019 06:09:11 AM
Old 02-19-2019
Quote:
Originally Posted by Neo
Welcome Back Akshay!

Are you going to hang around for a while?
Quote:
Originally Posted by Neo
Hey Akshay,

To follow up:

If you are OK and have time, I'll ask you to help me optimize after I have the new Vue.js-based UserCP up and running (out of the mockup and into the real-world usage). I have at least 80 hours of full-stack development work, I estimate, to get the this new CP to where I want it to be. If I work on this 4 hours a day, that is 20 days of work; so obviously I have a lot to do, and that's just a very rough estimate without taking pencil to paper.

As mentioned, I need to stay focused on the new CP build at this time and am not too worried about shaving milliseconds here and there off the site loading before caching. That is something good to do together, later this year. OK?
Sure, will use google closure compiler for minifying scripts, for css we have rewrite uri (Rewrite file-relative URIs as root-relative) first then can combine. I am not sure, VB has inbuilt tool already. We can think of serviceworkers after minifying resources (off course possible without minifying resources, but simply more http requests to server ).

For caching resources you can refer html5-boilerplate
https://raw.githubusercontent.com/h5...dist/.htaccess
This User Gave Thanks to Akshay Hegde For This Post:
 

4 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

sed remove css comments

Is there a way that I can use sed to remove lines with css comments like this? /* comment */ (9 Replies)
Discussion started by: gravesit
9 Replies

2. Web Development

On Css

<html> <head> <style> div.box {width: 300px; height: 200px; padding: 30px; font: 46 pt times new roman;} </style> </head> <body> <div class="box" style=" filter": progid:DXImagetransform.Microsoft.Alpha (Opacity=100, FinishOpacity=0, Style=1, StartX=0, FinishX=0,... (0 Replies)
Discussion started by: N-Training
0 Replies

3. Web Development

HTML down, CSS help, ahhhh

I am having some problems. I have been able to learn HTML, but when I try and encode CSS, nothing happens, what is the major issue here. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <title>MY CSS</title> <style... (7 Replies)
Discussion started by: N-Training
7 Replies

4. Web Development

CSS frameworks

I have been reading up on CSS frameworks, to see if it could be useful for an intranet that I am helping to build, but the true purpose does not become clear to me. What circumstances would the deployment of a CSS framework be useful in? What does a CSS framework do that a CMS template cannot do? (1 Reply)
Discussion started by: figaro
1 Replies
URI::SmartURI(3pm)					User Contributed Perl Documentation					URI::SmartURI(3pm)

NAME
URI::SmartURI - Subclassable and hostless URIs VERSION
Version 0.031 SYNOPSIS
my $uri = URI::SmartURI->new( 'http://host/foo/', { reference => 'http://host/bar/' } ); my $hostless = $uri->hostless; # '/foo/' $hostless->absolute; # 'http://host/foo/' $uri->relative; # '../foo/' DESCRIPTION
This is a sort of "subclass" of URI using delegation with some extra methods, all the methods that work for URIs will work on these objects as well. It's similar in spirit to URI::WithBase. It's also completely safe to subclass for your own use. CONSTRUCTORS
URI::SmartURI->new($str, [$scheme|{reference => $ref, scheme => $scheme}]) Takes a uri $str and an optional scheme or hashref with a reference uri (for computing relative/absolute URIs) and an optional scheme. my $uri = URI::SmartURI->new('http://dev.catalyst.perl.org/'); my $uri = URI::SmartURI->new('/dev.catalyst.perl.org/new-wiki/', 'http'); my $uri = URI::SmartURI->new( 'http://search.cpan.org/~jrockway/Catalyst-Manual-5.701003/', { reference => 'http://search.cpan.org/' } ); The object returned will be blessed into a scheme-specific subclass, based on the class of the underlying $uri->obj (URI object.) For example, URI::SmartURI::http, which derives from URI::SmartURI (or $uri->factory_class if you're subclassing.) URI::SmartURI->new_abs($str, $base_uri) Proxy for URI->new_abs URI::SmartURI->newlocal($filename, [$os]) Proxy for URI::URL->newlocal METHODS
$uri->hostless Returns the URI with the scheme and host parts stripped. $uri->reference Accessor for the reference URI (for relative/absolute below.) $uri->relative Returns the URI relative to the reference URI. $uri->absolute Returns the absolute URI using the reference URI as base. "" stringification works, just like with URIs == and == does as well $uri->eq($other_uri) Explicit equality check to another URI, can be used as URI::SmartURI::eq($uri1, $uri2) as well. $uri->obj Accessor for the URI object methods are delegated to. $uri->factory_class The class whose constructor was called to create the $uri object, usually URI::SmartURI or your own subclass. This is used to call class (rather than object) methods. INTERNAL METHODS
These are used internally by SmartURI, and are not interesting for general use, but may be useful for writing subclasses. $uri->_opts Returns a hashref of options for the $uri (reference and scheme.) $class->_resolve_uri_class($uri_class) Converts, eg., "URI::http" to "URI::SmartURI::http". $class->_make_uri_class($uri_class) Creates a new proxy class class for a URI class, with all exports and constructor intact, and returns its name, which is made using _resolve_uri_class (above). $class->_inflate_uris(@rray, $opts) Inflate any URI objects in @rray into URI::SmartURI objects, all other members pass through unharmed. $opts is a hashref of options to include in the objects created. $class->_deflate_uris(@rray) Deflate any URI::SmartURI objects in @rray into the URI objects they are proxies for, all other members pass through unharmed. MAGICAL IMPORT
On import with the "-import_uri_mods" flag it loads all the URI .pms into your class namespace. This works: use URI::SmartURI '-import_uri_mods'; use URI::SmartURI::WithBase; use URI::SmartURI::URL; my $url = URI::SmartURI::URL->new(...); # URI::URL proxy Even this works: use URI::SmartURI '-import_uri_mods'; use URI::SmartURI::Escape qw(%escapes); It even works with a subclass of URI::SmartURI. I only wrote this functionality so that I could run the URI test suite without much modification, it has no real practical value. BUGS
Please report any bugs or feature requests to "bug-uri-smarturi at rt.cpan.org", or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=URI-SmartURI <http://rt.cpan.org/NoAuth/ReportBug.html?Queue=URI-SmartURI>. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes. SUPPORT
You can find documentation for this module with the perldoc command. perldoc URI::SmartURI You can also look for information at: o RT: CPAN's request tracker http://rt.cpan.org/NoAuth/Bugs.html?Dist=URI-SmartURI <http://rt.cpan.org/NoAuth/Bugs.html?Dist=URI-SmartURI> o AnnoCPAN: Annotated CPAN documentation http://annocpan.org/dist/URI-SmartURI <http://annocpan.org/dist/URI-SmartURI> o CPAN Ratings http://cpanratings.perl.org/d/URI-SmartURI <http://cpanratings.perl.org/d/URI-SmartURI> o Search CPAN http://search.cpan.org/dist/URI-SmartURI <http://search.cpan.org/dist/URI-SmartURI> SEE ALSO
Catalyst::Plugin::SmartURI, URI, URI::WithBase ACKNOWLEDGEMENTS
Thanks to folks on freenode #perl for helping me out when I was getting stuck, Somni, revdiablo, PerlJam and others whose nicks I forget. AUTHOR
Rafael Kitover, "<rkitover at cpan.org>" COPYRIGHT &; LICENSE Copyright (c) 2008 Rafael Kitover This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.12.4 2010-09-27 URI::SmartURI(3pm)
All times are GMT -4. The time now is 11:44 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy