Skip to content
This repository has been archived by the owner on Jan 21, 2021. It is now read-only.

tighten/gif-gif-react

Repository files navigation

Gif Gif

Because there's really only one way to pronounce it...

Introduction

This is the React version of the Vue code written by Samantha Geitz at Laracon 2018 during her talk "Jest Do It". You can find the Vue version of this project here.

It is a basic React/Laravel application with some tests written in Jest and Enzyme written to test front-end functionality.

Currently, this project is using an in-development version of Laravel Jest Presets. This package is NOT ON PACKAGIST AND PROBABLY NOT PRODUCTION READY, but you can use it if you are interested in trying out Jest easily in your Laravel applications!

Installation Instructions for a New React/Laravel/Jest Project

Run $ laravel new gif-gif-react

Optionally, install a CSS/UI framework like Tailwind CSS (if you are doing the latter, the Laravel Frontend Preset for Tailwind CSS package is highly recommended, although it will require additional config of your webpack.mix.js to match this project).

For easy installation of React and Jest, add the following to your composer.json file and run $ composer update:

"repositories": [
    {
        "type": "vcs",
        "url": "https://github.com/tightenco/laravel-preset-jest"
    }
],
"require": {
    "tightenco/laravel-preset-jest": "@dev"
},

To install React, do the following:

$ php artisan fe-preset react

This will install React, Jest and Enzyme (which can optionally be used for testing), the Babel presets you need, and update your webpack.mix.js file for React.

About

React version of Samantha Geitz's Jest Testing Laracon talk

Resources

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published