Git Product home page Git Product logo

doggostore's Introduction

DoggoStore

https://franks-teststore.myshopify.com/

created product categories for bed, bowl, collar, leash, brush, and harness created products for each category created products for dogs and cats

500 error

https://rmdevs.com/performance/shopping/summary [13:54:44] LOG.error: Undefined array key 0 {"userId":29,"exception":{}}

https://rmdevs.com/settings/location [13:58:34] LOG.error: Undefined array key 0 (View: /home/forge/rmdevs.com/resources/views/livewire/settings-location.blade.php) {"view":{"view":"/home/forge/rmdevs.com/vendor/laravel/framework/src/Illuminate/Collections/Collection.php","data":[]},"userId":29,"exception":{}}

Why the Shopify/Next.js/Tailwind CSS tech stack?

  • Loading, development, and deployment speed
    • faster loading = lower bounce rate = higher conversion
    • faster development = lower development costs
    • faster deployment = more iterations

environment set up

npm install -D tailwindcss@latest postcss@latest autoprefixer@latest
npm run dev

Deployment Fix

deployment settings on Vercel was stringifying a string, leading to a failure to fetch products. fixed by deleting quotes on environmental variables

Testing

Resources

https://nextjs.org/docs/testing#jest-and-react-testing-library

Step 1

Run terminal command:

npm install --save-dev jest jest-environment-jsdom @testing-library/react @testing-library/jest-dom

Step 2

create a file in the root named jest.config.js add the following:

// jest.config.js
const nextJest = require("next/jest");

const createJestConfig = nextJest({
	// Provide the path to your Next.js app to load next.config.js and .env files in your test environment
	dir: "./",
});

// Add any custom config to be passed to Jest
/** @type {import('jest').Config} */
const customJestConfig = {
	// Add more setup options before each test is run
	// setupFilesAfterEnv: ['<rootDir>/jest.setup.js'],
	// if using TypeScript with a baseUrl set to the root directory then you need the below for alias' to work
	moduleDirectories: ["node_modules", "<rootDir>/"],
	testEnvironment: "jest-environment-jsdom",
};

// createJestConfig is exported this way to ensure that next/jest can load the Next.js config which is async
module.exports = createJestConfig(customJestConfig);

Step 3

add the following script in package.json

"scripts": {
  "dev": "next dev",
  "build": "next build",
  "start": "next start",
  "test": "jest --watch"
}

Step 4

  • create a file named [_ _ tests_ _] (no spaces)
  • add tests

To-Do

  • add comments to ./pages
  • add icon to page tab
  • add conditional screen rendering for cards
  • navbar transparency issue

Git Maintenance

to update remote branches

git remote update origin --prune

styling

dark mode

https://tailwindcss.com/docs/dark-mode

added light blue hover text to give the dark mode more styling

doggostore's People

Contributors

f-rivers avatar

Watchers

 avatar

doggostore's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.