
<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>NPM Package Archives - TECHNIG</title>
	<atom:link href="https://www.technig.com/tag/npm-package/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.technig.com/tag/npm-package/</link>
	<description>Gateway for IT Experts and Tech Geeks</description>
	<lastBuildDate>Sun, 26 Jul 2020 09:44:26 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.6.2</generator>

<image>
	<url>https://www.technig.com/wp-content/uploads/2020/04/32x32.png</url>
	<title>NPM Package Archives - TECHNIG</title>
	<link>https://www.technig.com/tag/npm-package/</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">162720667</site>	<item>
		<title>How to Make NPM Work 20 Times Faster</title>
		<link>https://www.technig.com/make-npm-install-work-20-times-faster/</link>
					<comments>https://www.technig.com/make-npm-install-work-20-times-faster/#comments</comments>
		
		<dc:creator><![CDATA[Hujatulla Asghari]]></dc:creator>
		<pubDate>Fri, 17 Nov 2017 11:34:04 +0000</pubDate>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Coding]]></category>
		<category><![CDATA[Coding Tips]]></category>
		<category><![CDATA[Command Line Tips]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[How to Fix]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Nodejs]]></category>
		<category><![CDATA[NPM Install]]></category>
		<category><![CDATA[NPM Package]]></category>
		<category><![CDATA[PowerShell Articles]]></category>
		<category><![CDATA[Tutorial]]></category>
		<category><![CDATA[Web Design]]></category>
		<category><![CDATA[Web Designing]]></category>
		<category><![CDATA[Web Developer]]></category>
		<guid isPermaLink="false">https://www.technig.com/?p=13692</guid>

					<description><![CDATA[<div style="margin-bottom:20px;"><img width="840" height="420" src="https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig.jpg" class="attachment-post-thumbnail size-post-thumbnail wp-post-image" alt="Make NPM install Work 20 Times Faster Step by Step - Technig" decoding="async" fetchpriority="high" srcset="https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig.jpg 840w, https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig-300x150.jpg 300w, https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig-768x384.jpg 768w" sizes="(max-width: 840px) 100vw, 840px" /></div>
<p>As a developer or web designer, we use NPM almost more than 5 times on average per day. Sometimes, it takes a long time to install a package. Even more than 5 minutes or more. Besides, you watch some people on tutorials who install a package in 5 seconds. How they do that? If you [&#8230;]</p>
<p>The post <a href="https://www.technig.com/make-npm-install-work-20-times-faster/">How to Make NPM Work 20 Times Faster</a> appeared first on <a href="https://www.technig.com">TECHNIG</a>.</p>
]]></description>
										<content:encoded><![CDATA[<div style="margin-bottom:20px;"><img width="840" height="420" src="https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig.jpg" class="attachment-post-thumbnail size-post-thumbnail wp-post-image" alt="Make NPM install Work 20 Times Faster Step by Step - Technig" decoding="async" srcset="https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig.jpg 840w, https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig-300x150.jpg 300w, https://www.technig.com/wp-content/uploads/2017/11/Make-NPM-install-Work-20-Times-Faster-Step-by-Step-Technig-768x384.jpg 768w" sizes="(max-width: 840px) 100vw, 840px" /></div><p>As a developer or web designer, we use <a href="https://www.technig.com/tag/npm-package/">NPM </a>almost more than 5 times on average per day. Sometimes, it takes a long time to install a package. Even more than 5 minutes or more. Besides, you watch some people on tutorials who install a package in 5 seconds. How they do that? If you want to make NPM install Work 20 times faster, this tutorial will help you.</p>
<h2>Why NPM install is Too Slow?</h2>
<p>Before we make NPM work faster, we should know what are the reasons why NPM install is too Slow. Well, there are many reasons. We just mention a few of them. So, if you are using Mac, it&#8217;s faster than the PC. Because all Apple MacBooks are having <a href="https://en.wikipedia.org/wiki/Solid-state_drive">SSD </a>hard drive. Also, most SSD drives are 5 to 10 times faster than HDD hard drives. Therefore, your computer might work slow.</p>
<p>If you have Mac or PC with<a href="https://www.technig.com/upgrade-laptop-hard-disk-to-ssd/"> SSD hard </a>drive and still your NPM install command work slow, you can make it faster by following the tutorial. Also, <strong>this method works for HDD drives as well. </strong></p>
<h2>Make NPM Install<span style="font-size: 16px;">  </span>Work 20 Times Faster</h2>
<p>1. The first way to make <span style="background-color: #f6d5d9;">NPM </span>install faster is to make the progress set to false. So, this makes NPM install packages without showing the progress status.</p>
<pre class="theme:terminal lang:default decode:true">npm set progress=false</pre>
<p>It makes NPM install run 2x faster.</p>
<p>2. The second way is to use PNPM. It&#8217;s fast, disk space-efficient package manager. Besides, it&#8217;s a lot faster than NPM and Yarn. The way it works is similar to NPM. Also, as the documentation says, it supports almost 80% of NPM commands.</p>
<p>Features:</p>
<ul>
<li><strong>Fast.</strong> Faster than <span style="background-color: #f6d5d9;">NPM </span>and Yarn.</li>
<li><strong>Efficient.</strong> One version of a package is saved only ever once on a disk.</li>
<li><strong>Deterministic.</strong> It has a lock file called.<code>shrinkwrap.yaml</code></li>
<li><strong>Strict.</strong> A package can access only dependencies that are specified in its.<code>package.json</code></li>
<li><strong>Works everywhere.</strong> Works on Windows, Linux and OS X.</li>
</ul>
<p>Here is how you install and use it. Assuming you have NPM.</p>
<pre class="theme:terminal lang:default decode:true ">npm install -g pnpm</pre>
<p>Now, instead of using NPM install, use PNPM install. For example.</p>
<pre class="theme:terminal lang:default decode:true ">pnpm install bootstrap</pre>
<p>But you should remember, it will not work if you don&#8217;t have the file<code>package.json</code>.</p>
<pre class="theme:terminal lang:default decode:true ">npm init -y</pre>
<p>Before using PNPM install command, run <code> npm init -y</code> to create an empty <code>package.json</code>file.</p>
<p><span style="background-color: #f6d5d9;">NPM </span>commands that are re-implemented in PNPM:</p>
<ul>
<li><code>install</code></li>
<li><code>update</code></li>
<li><code>uninstall</code></li>
<li><code>link</code></li>
<li><code>prune</code></li>
<li><code>list</code></li>
<li><code>install-test</code></li>
<li><code>outdated</code></li>
<li><code>rebuild</code></li>
<li><code>root</code></li>
<li><code>help</code></li>
</ul>
<p>You can read more <a href="https://github.com/pnpm/pnpm">here </a>about it.</p>
<h2>Conclusion</h2>
<p>I hope it has been informative for you and y help you. If you have any questions, feel free to comment below. Besides, you can join our forum and ask questions there.</p>
<p>The post <a href="https://www.technig.com/make-npm-install-work-20-times-faster/">How to Make NPM Work 20 Times Faster</a> appeared first on <a href="https://www.technig.com">TECHNIG</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.technig.com/make-npm-install-work-20-times-faster/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">13692</post-id>	</item>
		<item>
		<title>How to Use Laravel Mix without Laravel Step by Step</title>
		<link>https://www.technig.com/use-laravel-mix-without-laravel/</link>
					<comments>https://www.technig.com/use-laravel-mix-without-laravel/#respond</comments>
		
		<dc:creator><![CDATA[Hujatulla Asghari]]></dc:creator>
		<pubDate>Thu, 12 Oct 2017 09:30:08 +0000</pubDate>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Coding]]></category>
		<category><![CDATA[CSS Solution]]></category>
		<category><![CDATA[CSS Tips]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Laravel Tutorials]]></category>
		<category><![CDATA[Nodejs]]></category>
		<category><![CDATA[NPM Package]]></category>
		<category><![CDATA[Small Business Web Design]]></category>
		<category><![CDATA[Web Designing]]></category>
		<category><![CDATA[Web Developer]]></category>
		<category><![CDATA[Web Development Company]]></category>
		<guid isPermaLink="false">https://www.technig.com/?p=11966</guid>

					<description><![CDATA[<div style="margin-bottom:20px;"><img width="840" height="420" src="https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel.jpg" class="attachment-post-thumbnail size-post-thumbnail wp-post-image" alt="How to Use Laravel Mix without Laravel - Technig" decoding="async" srcset="https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel.jpg 840w, https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel-300x150.jpg 300w, https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel-768x384.jpg 768w" sizes="(max-width: 840px) 100vw, 840px" /></div>
<p>Laravel Mix is a powerful tool and NPM package. So, using Laravel Mix, you can compile sass, scss files, Vuejs files and ES6 features. Also, it&#8217;s fast and easy to start using. Besides, you can easily customizer Laravel Mix for your project. So, in this tutorial, you&#8217;ll learn how to use Laravel Mix without Laravel [&#8230;]</p>
<p>The post <a href="https://www.technig.com/use-laravel-mix-without-laravel/">How to Use Laravel Mix without Laravel Step by Step</a> appeared first on <a href="https://www.technig.com">TECHNIG</a>.</p>
]]></description>
										<content:encoded><![CDATA[<div style="margin-bottom:20px;"><img width="840" height="420" src="https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel.jpg" class="attachment-post-thumbnail size-post-thumbnail wp-post-image" alt="How to Use Laravel Mix without Laravel - Technig" decoding="async" loading="lazy" srcset="https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel.jpg 840w, https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel-300x150.jpg 300w, https://www.technig.com/wp-content/uploads/2017/10/How-to-Use-Laravel-Mix-without-Laravel-768x384.jpg 768w" sizes="(max-width: 840px) 100vw, 840px" /></div><p>Laravel Mix is a powerful tool and NPM package. So, using Laravel Mix, you can compile sass, scss files, Vuejs files and ES6 features. Also, it&#8217;s fast and easy to start using. Besides, you can easily customizer Laravel Mix for your project. So, in this tutorial, you&#8217;ll learn how to use Laravel Mix without Laravel project. The latest version of Laravel projects has pre-install Laravel Mix.</p>
<h2>Use Laravel Mix without Laravel Step by Step</h2>
<p>We are going to do everything step by step on how you can use Laravel Mix without Laravel, so you will not miss anything.</p>
<p><strong>Requirements:</strong></p>
<p>We require the following criteria. If you want to follow the tutorial to make sure you have the NPM and Nodejs installed on your system. If you don&#8217;t have installed those, then go to <a href="https://nodejs.org/" rel="noopener">nodejs.org</a>, download and install. It will not take more than 2 minutes. Besides, you must have basic knowledge of NPM usage.</p>
<h3>1. Create a Project</h3>
<p>Simply, create a folder anywhere on your computer. Then run the following command to initialize NPM files.</p>
<pre class="lang:default decode:true">npm init -y</pre>
<p>The command creates a package.Json file in your folder with simple boilerplate. <strong>Then</strong>, open your project in your favorite text editor.</p>
<h3>2. Install NPM Packages</h3>
<p>Now, let&#8217;s install a few NPM package plus Laravel Mix. <strong>So</strong>, we&#8217;re going to install all of them at once. To do so, list your packages name in your package.json file.</p>
<p>So, open your <strong>package.json</strong> file and add the following code. We will install a few essential packages.</p>
<pre class="theme:sublime-text lang:java decode:true">{
  "name": "laravel-mix",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
        "development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
        "watch": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
        "watch-poll": "npm run watch -- --watch-poll",
        "hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js",
        "production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
    },
    "devDependencies": {
        "laravel-mix": "^1.0",
        "bootstrap-sass": "^3.3.7",
        "cross-env": "^5.0.1",
        "jquery": "^3.1.1",
        "vue": "^2.1.10"
  },

  "keywords": [],
  "author": "",
  "license": "ISC"
}
</pre>
<p>So, your<strong> package.json</strong> file should look like the above. The <strong>devDependencies</strong> part is the list of packages we want to install. So, run now <strong>run</strong> the following command in your command line to download the packages.</p>
<pre class="lang:default decode:true">npm install</pre>
<p>It will take a while to install the packages, so be patient. So, after installing completed, continue the next step.</p>
<h3>3. Configure the Laravel Mix Files</h3>
<p>After installing the packages, now you can start creating Laravel mix files.</p>
<p>You go to &#8220;<span style="background-color: #c2c2c2;"><em>node_modules/laravel-mix/setup/webpack.mix.js&#8221;</em></span> and copy the <strong>webpack.mix.js</strong> file to the root directory of your project. Also, you can create the file yourself and add the following code inside.</p>
<p><strong>webpack.mix.js</strong></p>
<pre class="theme:sublime-text lang:js decode:true">let mix = require('laravel-mix');

mix.js('src/app.js', 'dist/')
   .sass('src/app.scss', 'dist/');</pre>
<p>The above just require Laravel mix, then look in &#8220;<strong>src/app.js</strong>&#8221; and compile to &#8220;<strong>dist/</strong>&#8221; folder. So, we need the create those files.</p>
<figure id="attachment_11973" aria-describedby="caption-attachment-11973" style="width: 660px" class="wp-caption aligncenter"><a href="http://3.90.216.52/wp-content/uploads/2017/10/Laravel-Mix-Folder-Structure.png"><img loading="lazy" decoding="async" class="wp-image-11973" src="http://3.90.216.52/wp-content/uploads/2017/10/Laravel-Mix-Folder-Structure.png" alt="Laravel Mix Folder Structure" width="660" height="306" srcset="https://www.technig.com/wp-content/uploads/2017/10/Laravel-Mix-Folder-Structure.png 731w, https://www.technig.com/wp-content/uploads/2017/10/Laravel-Mix-Folder-Structure-300x139.png 300w" sizes="(max-width: 660px) 100vw, 660px" /></a><figcaption id="caption-attachment-11973" class="wp-caption-text">Laravel Mix Folder Structure</figcaption></figure>
<h3>4. Add Code to Compile</h3>
<p>Now let&#8217;s add some code our <strong>app.js</strong> file to compile and test if everything is working.</p>
<p>So, add the following code in your app.js file. It&#8217;s just for the demo, of course, you can add any code you want.</p>
<pre class="theme:sublime-text lang:js decode:true">window.$ = window.jQuery = require('jquery');
require('bootstrap-sass');

</pre>
<p>The code will add jQuery and bootstrap file.</p>
<p><strong>Now</strong>, open your command line and run the following code.</p>
<pre class="lang:default decode:true">npm run production</pre>
<p>The <strong><em>production</em> </strong>and other command list are written in<strong> the package.Json</strong> file.</p>
<p>For me, the compilation starts and go till 95%. Then it stopped.</p>
<figure id="attachment_11976" aria-describedby="caption-attachment-11976" style="width: 525px" class="wp-caption aligncenter"><a href="http://3.90.216.52/wp-content/uploads/2017/10/Laravel-mix-stop-at-emitting.png"><img loading="lazy" decoding="async" class="wp-image-11976" src="http://3.90.216.52/wp-content/uploads/2017/10/Laravel-mix-stop-at-emitting.png" alt="Laravel mix stop at emitting" width="525" height="215" srcset="https://www.technig.com/wp-content/uploads/2017/10/Laravel-mix-stop-at-emitting.png 872w, https://www.technig.com/wp-content/uploads/2017/10/Laravel-mix-stop-at-emitting-300x123.png 300w, https://www.technig.com/wp-content/uploads/2017/10/Laravel-mix-stop-at-emitting-768x314.png 768w" sizes="(max-width: 525px) 100vw, 525px" /></a><figcaption id="caption-attachment-11976" class="wp-caption-text">Laravel mix stop at emitting</figcaption></figure>
<p>It&#8217;s not going further. So, there must be a problem.</p>
<h2>5. How to Fix Laravel Mix 95% emitting Stop Problem</h2>
<p>So, let&#8217;s fix it. Before doing that, you know know what&#8217;s the problem. Thus, it can&#8217;t find the public folder or where to compile the files. Here is how you fix it.</p>
<p>Open your <strong>webpack.mix.js</strong> file and add the following code<strong> right after</strong> you require Laravel Mix.</p>
<pre class="theme:sublime-text lang:js decode:true">mix.options({
    publicPath: 'dist'
})
</pre>
<p>Now, terminate the emitting process by pressing Ctrl + C two times and re-run the production command. It should work now.</p>
<h3>Conclusion</h3>
<p>We hope this article has been informative for you and you enjoyed reading. So, it&#8217; how you can use Laravel Mix without Laravel. Further, we have a forum where you can ask any types of questions and get instant answers. So, feel free to join us.</p>
<p>The post <a href="https://www.technig.com/use-laravel-mix-without-laravel/">How to Use Laravel Mix without Laravel Step by Step</a> appeared first on <a href="https://www.technig.com">TECHNIG</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.technig.com/use-laravel-mix-without-laravel/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">11966</post-id>	</item>
	</channel>
</rss>
