{"id":68349,"date":"2021-08-01T10:44:30","date_gmt":"2021-08-01T14:44:30","guid":{"rendered":"http:\/\/bangla.salearningschool.com\/recent-posts\/optimizing-angularjs-page-loading-angularjs-by-sayed-ahmed\/"},"modified":"2021-08-01T10:44:30","modified_gmt":"2021-08-01T14:44:30","slug":"optimizing-angularjs-page-loading-angularjs-by-sayed-ahmed","status":"publish","type":"post","link":"http:\/\/bangla.sitestree.com\/?p=68349","title":{"rendered":"Optimizing AngularJS Page Loading #AngularJS #By Sayed Ahmed"},"content":{"rendered":"<p>Optimizing AngularJS Page Loading:<\/p>\n<p>Optimizing web-applications for faster performance often include reducing network activities, reducing send and receive requests over the network\/internet, and reducing data downloads. Minification of JavaScript, CSS, and HTML files can help with that. AngularJS kind of forces to write minification safe JavaScript, and writing array style and annotation based function declaration is recommended.<\/p>\n<p>Creating partial templates and loading related templates in combination may help. Probably, need some experiment and planning before than doing it on the fly. Two ways to preload templates 1. &lt;script&gt; tag 2. $templateCache<\/p>\n<p>You may want to read one of our other articles on optimising landing pages for AngularJS single page applications by using ng-cloak, and ng-bind.<\/p>\n<p>Using Asynchronous script loader such as Require.Js does not improve the performance a lot [according to the book as listed in the reference section]. Hence, so far, AMD is not recommended with AngularJS.<\/p>\n<p>You can check how to use Require.JS in your applications at : http:\/\/requirejs.org\/docs\/start.html . You may want to use them in non-AngularJS projects. The idea is, you have to have a consistent project directory structure esp for JavaScript files as recommended and specified by Require.Js. In your, HTML file you refer to the main.js file, single entry point for loading JS code. In that main.js, you will use Require.JS esp. require() to load other JS files asynchronously and as required by your application.<\/p>\n<p>To use Require.JS with JQuery, you can check the following resource. The adoption may need different considerations for a new project or for adapting existing code for Require.JS<br \/>\nhttp:\/\/requirejs.org\/docs\/jquery.html From: http:\/\/sitestree.com\/?p=836<br \/> Categories:AngularJS, By Sayed Ahmed<br \/>Tags:<br \/> Post Data:2014-02-15 23:43:41<\/p>\n<p>\t\tShop Online: <a href='https:\/\/www.ShopForSoul.com\/' target='new' rel=\"noopener\">https:\/\/www.ShopForSoul.com\/<\/a><br \/>\n\t\t(Big Data, Cloud, Security, Machine Learning): Courses: <a href='http:\/\/Training.SitesTree.com' target='new' rel=\"noopener\"> http:\/\/Training.SitesTree.com<\/a><br \/>\n\t\tIn Bengali: <a href='http:\/\/Bangla.SaLearningSchool.com' target='new' rel=\"noopener\">http:\/\/Bangla.SaLearningSchool.com<\/a><br \/>\n\t\t<a href='http:\/\/SitesTree.com' target='new' rel=\"noopener\">http:\/\/SitesTree.com<\/a><br \/>\n\t\t8112223 Canada Inc.\/JustEtc: <a href='http:\/\/JustEtc.net' target='new' rel=\"noopener\">http:\/\/JustEtc.net (Software\/Web\/Mobile\/Big-Data\/Machine Learning) <\/a><br \/>\n\t\tShop Online: <a href='https:\/\/www.ShopForSoul.com'> https:\/\/www.ShopForSoul.com\/<\/a><br \/>\n\t\tMedium: <a href='https:\/\/medium.com\/@SayedAhmedCanada' target='new' rel=\"noopener\"> https:\/\/medium.com\/@SayedAhmedCanada <\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Optimizing AngularJS Page Loading: Optimizing web-applications for faster performance often include reducing network activities, reducing send and receive requests over the network\/internet, and reducing data downloads. Minification of JavaScript, CSS, and HTML files can help with that. AngularJS kind of forces to write minification safe JavaScript, and writing array style and annotation based function declaration &hellip; <\/p>\n<p><a class=\"more-link btn\" href=\"http:\/\/bangla.sitestree.com\/?p=68349\">Continue reading<\/a><\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1917],"tags":[],"class_list":["post-68349","post","type-post","status-publish","format-standard","hentry","category-fromsitestree-com","item-wrap"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":5773,"url":"http:\/\/bangla.sitestree.com\/?p=5773","url_meta":{"origin":68349,"position":0},"title":"AngularJS \u099f\u09bf\u0989\u099f\u09cb\u09b0\u09bf\u09df\u09be\u09b2 (AngularJS Tutorial in Bangla)","author":"Author-Check- Article-or-Video","date":"January 19, 2015","format":false,"excerpt":"\u09ae\u09c3\u09a4\u09cd\u09af\u09c1\u099e\u09cd\u099c\u09df \u09ac\u09bf\u09b6\u09cd\u09ac\u09be\u09b8 \u00a0 AngularJS, HTML \u0995\u09c7 \u09a8\u09a4\u09c1\u09a8 \u098f\u099f\u09cd\u09b0\u09bf\u09ac\u09bf\u0989\u099f \u09a6\u09cd\u09ac\u09be\u09b0\u09be \u09ac\u09c3\u09b8\u09cd\u09a4\u09c3\u09a4 \u0995\u09b0\u09c7\u0964 AngularJS, SPA (Single Page Applications) \u098f\u09b0 \u099c\u09a8\u09cd\u09af \u0989\u09a4\u09cd\u09a4\u09ae \u0964 AngularJS \u09b6\u09c7\u0996\u09be \u09b8\u09b9\u099c \u0964 \u00a0 \u098f\u0987 \u099f\u09bf\u0989\u099f\u09cb\u09b0\u09bf\u09af\u09bc\u09be\u09b2\u099f\u09bf\u09a4\u09c7 \u09af\u09be \u09b0\u09df\u09c7\u099b\u09c7 \u098f\u0987 \u099f\u09bf\u0989\u099f\u09cb\u09b0\u09bf\u09af\u09bc\u09be\u09b2\u099f\u09bf \u098f\u09ae\u09a8\u09ad\u09be\u09ac\u09c7 \u09a1\u09bf\u099c\u09be\u0987\u09a8 \u0995\u09b0\u09be \u09b9\u09df\u09c7\u099b\u09c7 \u09af\u09be\u09a4\u09c7 \u0986\u09aa\u09a8\u09bf \u0985\u09a4\u09bf \u09a6\u09cd\u09b0\u09c1\u09a4 \u0993 \u09a6\u0995\u09cd\u09b7\u09a4\u09be\u09b0 \u09b8\u09be\u09a5\u09c7 AngularJS \u09b6\u09bf\u0996\u09a4\u09c7 \u09aa\u09be\u09b0\u09c7\u09a8 \u0964 \u09aa\u09cd\u09b0\u09a5\u09ae\u09c7 \u0986\u09aa\u09a8\u09bf AngularJS \u098f\u09b0\u2026","rel":"","context":"In &quot;AngularJS - 001&quot;","block_context":{"text":"AngularJS - 001","link":"http:\/\/bangla.sitestree.com\/?cat=154"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/fc07.deviantart.net\/fs71\/f\/2013\/333\/8\/2\/angularjs_by_abhishekghosh-d6w57fs.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":68353,"url":"http:\/\/bangla.sitestree.com\/?p=68353","url_meta":{"origin":68349,"position":1},"title":"Securing Your AngularJS Applications #AngularJS #By Sayed Ahmed","author":"Author-Check- Article-or-Video","date":"August 1, 2021","format":false,"excerpt":"Securing Your AngularJS Applications Some security measures can be as follows: Take security measures at the entry and exit points of data to and from the server Secure the server and prevent unauthorized access to data, and HTML Encrypt the connection i.e https:\/\/ Prevent cross-site scripting (XSS), Prevent cross-site request\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":7442,"url":"http:\/\/bangla.sitestree.com\/?p=7442","url_meta":{"origin":68349,"position":2},"title":"AngularJS Templates \u098f\u09b0 \u09a8\u09bf\u09b0\u09be\u09aa\u09a4\u09cd\u09a4\u09be\u0964","author":"Author-Check- Article-or-Video","date":"March 23, 2015","format":false,"excerpt":"URL of translated tutorial http:\/\/sitestree.com\/securing-your-angularjs-applications\/ Paste written translation here AngularJS Templates \u098f\u09b0 \u09a8\u09bf\u09b0\u09be\u09aa\u09a4\u09cd\u09a4\u09be\u0964 Md. Shahinoor Islam \u09af\u09a6\u09bf \u0986\u09aa\u09a8\u09bf \u099a\u09be\u09a8 \u09a4\u09ac\u09c7 \u0986\u09aa\u09a8\u09bf \u098f\u099f\u09be ($templateCache caches templates) \u09ac\u09cd\u09af\u09ac\u09b9\u09be\u09b0 \u0995\u09b0\u09a4\u09c7 \u09aa\u09be\u09b0\u09c7\u09a8\u0964 \u09aa\u09cd\u09b0\u09a4\u09cd\u09af\u09c7\u0995 user \u0995\u09c7 login \u0995\u09b0\u09be\u09b0 \u09b8\u09ae\u09df cache \u099f\u09be remove \u0995\u09b0\u09a4\u09c7 \u09b9\u09ac\u09c7\u0964 \u09a8\u09bf\u099a\u09c7\u09b0 \u0989\u09a6\u09be\u09b9\u09b0\u09a8\u099f\u09bf \u0986\u09aa\u09a8\u09be\u0995\u09c7 \u09b8\u09be\u09b9\u09be\u09af\u09cd\u09af \u0995\u09b0\u09ac\u09c7, Cache-Control: no-cache, no-store, must-revalidate Pragma :\u2026","rel":"","context":"In &quot;AngularJS - 001&quot;","block_context":{"text":"AngularJS - 001","link":"http:\/\/bangla.sitestree.com\/?cat=154"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":5775,"url":"http:\/\/bangla.sitestree.com\/?p=5775","url_meta":{"origin":68349,"position":3},"title":"AngularJS \u09aa\u09b0\u09bf\u099a\u09bf\u09a4\u09bf (AngularJS Introduction in Bangla)","author":"Author-Check- Article-or-Video","date":"January 19, 2015","format":false,"excerpt":"\u09aa\u09be\u09b0\u09bf\u099c\u09be\u09a4 \u09ac\u09bf\u09b6\u09cd\u09ac\u09be\u09b8 AngularJS \u098f\u0995\u099f\u09bf JavaScript \u098f\u09b0 framework \u0964 \u098f\u099f\u09bf HTML \u09aa\u09c7\u099c\u09c7\u09b0 \u09b8\u09be\u09a5\u09c7 <script> tag \u098f\u09b0 \u09ae\u09be\u09a7\u09cd\u09af\u09ae\u09c7 \u09af\u09cb\u0997 \u0995\u09b0\u09be \u09b9\u09df\u0964 AngularJS \u098f\u0987\u099a\u099f\u09bf\u098f\u09ae\u098f\u09b2 \u098f\u099f\u09cd\u09b0\u09bf\u09ac\u09bf\u0989\u099f \u098f\u09b0 \u09a8\u09bf\u09b0\u09cd\u09a6\u09c7\u09b6\u09a8\u09be (Directive) \u0985\u09a8\u09c1\u09b8\u09be\u09b0\u09c7 \u09aa\u09cd\u09b0\u09b8\u09be\u09b0\u09bf\u09a4 \u0995\u09b0\u09c7 \u098f\u09ac\u0982 HTML \u098f\u09b0 Expression \u098f\u09b0 \u09b8\u09be\u09a5\u09c7 \u09a4\u09a5\u09cd\u09af \u09ae\u09bf\u09b6\u09cd\u09b0\u09bf\u09a4 \u0995\u09b0\u09c7 \u0964 \u00a0 AngularJS \u098f\u0995\u099f\u09bf JavaScript Framework AngularJS \u098f\u0995\u099f\u09bf JavaScript Framework \u0964 \u098f\u099f\u09be JavaScript\u2026","rel":"","context":"In &quot;AngularJS - 001&quot;","block_context":{"text":"AngularJS - 001","link":"http:\/\/bangla.sitestree.com\/?cat=154"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":5779,"url":"http:\/\/bangla.sitestree.com\/?p=5779","url_meta":{"origin":68349,"position":4},"title":"\u0985\u09cd\u09af\u09be\u0999\u09cd\u0997\u09c1\u09b2\u09be\u09b0 \u099c\u09c7\u098f\u09b8 \u098f\u0995\u09cd\u09b8\u09aa\u09cd\u09b0\u09c7\u09b6\u09a8 (AngularJS Expressions in Bangla)","author":"Author-Check- Article-or-Video","date":"January 22, 2015","format":false,"excerpt":"\u0985\u09cd\u09af\u09be\u0999\u09cd\u0997\u09c1\u09b2\u09be\u09b0 \u099c\u09c7\u098f\u09b8 (AngularJS) \u098f\u0995\u09cd\u09b8\u09aa\u09cd\u09b0\u09c7\u09b6\u09a8 (Expressions) Article By: Protap Chandra \u00a0 AngularJS Expressions \u09ac\u09cd\u09af\u09ac\u09b9\u09be\u09b0 \u0995\u09b0\u09c7 HTML \u098f\u09b0 \u09b8\u0999\u09cd\u0997\u09c7 \u09a1\u09be\u099f\u09be \u0986\u09ac\u09a6\u09cd\u09a7 (bind) \u0995\u09b0\u09be \u09b9\u09df\u0964 AngularJS expression \u09a6\u09cd\u09ac\u09bf\u09a4\u09c0\u09df \u09ac\u09a8\u09cd\u09a7\u09a8\u09c0\u09b0 \u09ad\u09c7\u09a4\u09b0 \u09b2\u09c7\u0996\u09be \u09b9\u09df: {{ expression }}. expression HTML \u098f\u09b0 \u09b8\u0999\u09cd\u0997\u09c7 ng-bind directive \u098f\u09b0 \u09ae\u09a4\u09cb \u098f\u0995\u0987 \u09ad\u09be\u09ac\u09c7 \u09a1\u09be\u099f\u09be \u0986\u09ac\u09a6\u09cd\u09a7 \u0995\u09b0\u09c7\u0964 \u09a0\u09bf\u0995 \u09af\u09c7\u0996\u09be\u09a8\u09c7 expression \u09b2\u09c7\u0996\u09be \u09b9\u09ac\u09c7\u2026","rel":"","context":"In &quot;AngularJS - 001&quot;","block_context":{"text":"AngularJS - 001","link":"http:\/\/bangla.sitestree.com\/?cat=154"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":5792,"url":"http:\/\/bangla.sitestree.com\/?p=5792","url_meta":{"origin":68349,"position":5},"title":"AngularJS \u09a1\u09bf\u09b0\u09c7\u0995\u09cd\u099f\u09bf\u09ad (AngularJS Directives in Bangla)","author":"Author-Check- Article-or-Video","date":"January 27, 2015","format":false,"excerpt":"\u09aa\u09b0\u09be\u099c\u09bf\u09a4 \u09ac\u09bf\u09b6\u09cd\u09ac\u09be\u09b8 \u00a0 AngularJs \u0986\u09aa\u09a8\u09be\u0995\u09c7 \u09a8\u09a4\u09c1\u09a8 \u098f\u099f\u09cd\u09b0\u09bf\u09ac\u09bf\u0989\u099f Directives \u098f\u09b0 \u09ae\u09be\u09a7\u09cd\u09af\u09ae\u09c7 html \u0995\u09c7 \u09ac\u09cd\u09af\u09be\u0996\u09cd\u09af\u09be \u0995\u09b0\u09a4\u09c7 \u09b8\u09be\u09b9\u09be\u09af\u09cd\u09af \u0995\u09b0\u09ac\u09c7 \u0964 AngularJS \u098f\u09b0 \u098f\u0995 \u09b8\u09c7\u099f \u09ac\u09bf\u09b2\u09cd\u099f \u0987\u09a8 Directives \u0986\u099b\u09c7, \u09af\u09be \u0986\u09aa\u09a8\u09be\u09b0 \u09aa\u09cd\u09b0\u09a4\u09cd\u09af\u09c7\u0995\u099f\u09bf \u0985\u09cd\u09af\u09be\u09aa\u09cd\u09b2\u09bf\u0995\u09c7\u09b6\u09a8\u0995\u09c7 \u0995\u09be\u09b0\u09cd\u09af\u0995\u09b0\u09bf \u0995\u09b0\u09c7 \u09a4\u09cb\u09b2\u09c7\u0964 AngularJs \u0986\u09aa\u09a8\u09be\u0995\u09c7 \u0986\u09aa\u09a8\u09be\u09b0 \u09a8\u09bf\u099c\u09b8\u09cd\u09ac Directive \u09b8\u0982\u0999\u09cd\u0997\u09be\u09df\u09bf\u09a4 \u0995\u09b0\u09be\u09b0 \u09b8\u09c1\u09af\u09cb\u0997 \u09a6\u09c7\u09df\u0964 \u00a0 AngularJS \u09a1\u09bf\u09b0\u09c7\u0995\u09cd\u099f\u09bf\u09ad (AngularJS Directives) AngularJs \u0986\u09aa\u09a8\u09be\u0995\u09c7 ng- prefix\u2026","rel":"","context":"In &quot;AngularJS - 001&quot;","block_context":{"text":"AngularJS - 001","link":"http:\/\/bangla.sitestree.com\/?cat=154"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"_links":{"self":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/68349","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=68349"}],"version-history":[{"count":0,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/68349\/revisions"}],"wp:attachment":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=68349"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=68349"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=68349"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}