Install Larvel telescope for dev env

$ composer require laravel/telescope –dev Problem 1 – phpoffice/phpspreadsheet 1.5.2 requires ext-zip * $ sudo port install php72-zip   Problem 1 – dompdf/dompdf v0.8.2 requires ext-gd * $ sudo port install php72-gd php artisan telescope:install php artisan migrate php artisan telescope:publish After running telescope:install, you should remove the TelescopeServiceProvider service provider registration from your app configuration file. Instead, manually register …

How to fix _this.props.dispatch is not a function in React.JS

When you got error _this.props.dispatch is not a function, you can try below things: 1) Convert the (handleSubmit) function to an arrow function so in that case, it won’t have its own this. handleSubmit = (user) => { // …logic here } 2) Create a constructor inside the component and do the next step: this.handleSubmit = this.handleSubmit.bind(this) …

ReactJS support IE11/IE10/IE9/IE8

@php $ua = htmlentities($_SERVER[‘HTTP_USER_AGENT’], ENT_QUOTES, ‘UTF-8’); if (preg_match(‘~MSIE|Internet Explorer~i’, $ua) || (strpos($ua, ‘Trident’) !== false )) { //echo ‘<h3>Only for IE</h3>’ . $ua; echo'<script src=”https://cdnjs.cloudflare.com/ajax/libs/babel-polyfill/7.4.0/polyfill.min.js”></script>’; } @endphp

Sass .scss: Nesting and multiple classes? eg. div.myClass

use the parent selector reference &, it will be replaced by the parent selector after compilation: // override the text on the banner $banner-text-height : 125px; $anchor-hero-height : 75px; .hero-new-section { height: 300px; // default height and can be reset at back-end margin-bottom: $banner-text-height; background-position: 50% 50%; .new-hero-card { width: 100%; height: $banner-text-height; bottom: -$banner-text-height; …

How to fix Support for the experimental syntax ‘classProperties’ isn’t enabled

Error: esources/reactSkilledMigrantPoint/containers/TaskAddContainer.js failed (from ./node_modules/babel-loader/lib/index.js): F:\document_root_002\xinxilan.org\laravel\resources\reactSkilledMigrantPoint\containers\TaskAddContainer.js: Support for the experimental syntax ‘classProperties’ isn’t enabled (20:18): andleChange = event => { ^ this.setState({ [event.currentTarget.name]: event.currentTarget.value }); lugin-proposal-class-properties (https://git.io/vb4SL) to the ‘plugins’ section of your Babel config to enable transformation. t.raise (F:\document_root_002\xinxilan.org\laravel\node_modules\@babel\parser\lib\index.js:3851:17)   How to fix: add .babelrc to the root path: { “presets”: [ “@babel/preset-env”, “@babel/preset-react” …

How to fix Laravel/nova issue of mod_fcgid: ap_pass_brigade failed in handle_request_ipc function

from apache error log: [fcgid:warn] [pid 5577:tid 139792914306816] (32)Broken pipe: [client 131.203.140.1:53559] mod_fcgid: ap_pass_brigade failed in handle_request_ipc function,   From laravel storage error log: [2019-03-25 12:02:10] prod.ERROR: file_put_contents(): Exclusive locks are not supported for this stream {“exception”:”[object] (ErrorException(code: 0): file_put_contents(): Exclusive locks are not supported for this stream at /virtual/teamlocal-laravel-nova.devweb.co.nz/laravel/vendor/laravel/framework/src/Illuminate/Filesystem/Filesystem.php:122) #0 [internal function]: Illuminate\\Foundation\\Bootstrap\\HandleExceptions->handleError(2, ‘file_put_conten…’, …

How to fix “./composer.json” does not contain valid JSON

It something wrong in the composer.json file, check the config.platform  part: $ composer install [Composer\Json\JsonValidationException] “./composer.json” does not match the expected JSON schema: – config.platform : Array value found, but an object is required $ composer install[Seld\JsonLint\ParsingException] “./composer.lock” does not contain valid JSON Parse error on line 548: …-21T16:29:17+00:00″<<<<<<< HEAD======= ———————^ Expected one of: ‘EOF’, ‘}’, ‘:’, …

How to git merge one file from other branch to master

Step 1: clone from master git clone [email protected] Step 2: checkout the file from a branch $ git checkout dev Application/view/core/auth/email-reset.phtml error: pathspec ‘dev’ did not match any file(s) known to git. error: pathspec ‘Application/view/core/auth/email-reset.phtml’ did not match any file(s) known to git. $ ls Application/view/core/auth/email-reset.phtml ls: Application/view/core/auth/email-reset.phtml: No such file or directory $ git …