Posts

How to Start Django Project & how to Creat First project using Terminal Commands

Image
 How to StepUp New Django Project with python Virtual environment step 1: Need to create a virtual environment step-2: create Django Project Step-3 Setup Virtual environment in pycharm step-4: setup run/debug configuration in pycharm step-5: add App to Django Project  step-6: creating a Superuser to login via Django Admin Dashboard

Breaking up HTML tags in (react) JSX upon save - Solution

 go to visual studio and above left menu select Files -> Preferances -> Settings -> User Setting - GO to Down and check settings.json file _> open and add below code Add this code on settings.json file and save and run " files.associations " : { " *.js " : " javascriptreact " }

How to setup & install Django Cors Header

why we use Cors Headers in djnago: Simple, we need to communicate our application to other application we need to allow that url in our application, So we use this cors headers. how to Setup first install - pip install django-cors-headers Then goto settings.py: INSTALLED_APPS = ( ... 'corsheaders' , ... )   CORS_ORIGIN_WHITELIST = ( 'https://localhost:3001' , #your allowed urls 'https://127.0.0.1:3001' ) CORS_ORIGIN_ALLOW_ALL = True   MIDDLEWARE_CLASSES = ( ... 'corsheaders.middleware.CorsMiddleware' , 'django.middleware.common.CommonMiddleware' , ... )  After your run your application and Open your browser in cors disable mode: How to open in Browser cors disable mode: open terminal and type --> google-chrome --disable-web-security its open browser - type your CORS_ORIGIN_WHITELIST allowed url then its work.        

How To Disable Cors Headers In Browser & What is Cors & Why to Disable?

what is Cors & Why? I use this sometimes, for posting a local host fronted app to a local host backend API. I created a separate shortcut on my Windows 10 laptop, so that it never is used for normal browsing, only for debugging locally.  r How To Disable Cors Headers In Browser: The Following command can perform in terminal. Open terminal and enter the respected command and its automatically open Browser. OSX open -n -a /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --args --user-data-dir="/tmp/chrome_dev_test" --disable-web-security Linux google-chrome --disable-web-security If you need access to local files for dev purposes like AJAX or JSON, you can use -–allow-file-access-from-files flag. On Windows 10 command will be:   "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --disable-web-security --disable-gpu --user-data-dir=~/chromeTemp

How to install or Uninstalll google chrome in Ubuntu using Terminal

Install Google Chrome on Ubuntu 16.04 LTS/Ubuntu 17.10 from the Command Line For those of you who like to hone their command line skills, here is how to install Google Chrome on Ubuntu 16.04/17.10 using terminal. Press CTRL+ALT+T to open a terminal window, then edit   sources.list   file with   nano   text editor. You need to enter your password. sudo nano /etc/apt/sources.list Use the down arrow key to scroll to the bottom of this file. Copy the following APT line and paste it at the end of the file. deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main To save the file in Nano text editor, press   Ctrl+O , then press   Enter   to confirm. Next, press   CTRL+X   to exit out of this file. After that, enter the following command to download Google’s   signing key . wget https://dl.google.com/linux/linux_signing_key.pub Then use   apt-key   to add it to your keyring so the package manager can verify...

The Content Area Was Not Found in Your Page While Using Elementor

go to Appearance - Theme Editor go to template-home.php (Home Template Page Template (template-home.php)) add the_contect(); on 2nd line  and save, <?php the_content(); /* *   Template Name: Home Template */ hope hep full, please leave a comment

NPM run serve Error & NPM ERR! code ELIFECYCLE - Solution

cit246@cit246-ThinkPad-T430:~/Desktop/venkat/grafanacoreui$ npm run serve > @coreui/coreui-free-vue-admin-template@3.0.0 serve /home/cit246/Desktop/venkat/grafanacoreui > vue-cli-service serve  INFO  Starting development server...10% building 2/2 modules 0 activeevents.js:298       throw er; // Unhandled 'error' event       ^ Error: ENOSPC: System limit for number of file watchers reached, watch '/home/cit246/Desktop/venkat/grafanacoreui/public'     at FSWatcher.start (internal/fs/watchers.js:169:26)     at Object.watch (fs.js:1346:11)     at createFsWatchInstance (/home/cit246/Desktop/venkat/grafanacoreui/node_modules/chokidar/lib/nodefs-handler.js:38:15)     at setFsWatchListener (/home/cit246/Desktop/venkat/grafanacoreui/node_modules/chokidar/lib/nodefs-handler.js:81:15)     at FSWatcher.NodeFsHandler._watchWithNodeFs (/home/cit24...