1.4.14 • Published 4 months ago

framework-entersol-web v1.4.14

Weekly downloads
-
License
ISC
Repository
-
Last release
4 months ago

DBL COMPONENTS

INSTALATION

  1. BEFORE cloning this repo, create a new folder
  2. In that folder, clone this repository (git clone git@bitbucket.org:entersol-mx/framework-entersol.git)
  3. In the outer folder, add this package.json
{
  "scripts": {
    "babel": "yarn --cwd ./framework-entersol babel",
    "build": "yarn --cwd ./framework-entersol build"
  },
  "dependencies": {
    "@popperjs/core": "2.11.5",
    "bootstrap": "5.1.3",
    "flat": "^5.0.2",
    "react": "^17.0.1",
    "react-dom": "^17.0.1",
    "react-router": "^5.2.1",
    "react-router-dom": "^5.3.0",
    "sass": "^1.67.0",
    "swiper": "^6.8.3"
  },
  "devDependencies": {
    "@babel/cli": "^7.12.1",
    "@babel/core": "^7.12.3",
    "@babel/plugin-proposal-class-properties": "^7.12.1",
    "@babel/preset-env": "^7.12.1",
    "@babel/preset-react": "^7.12.5",
    "@babel/preset-typescript": "^7.12.1",
    "autoprefixer": "^10.0.1",
    "babel-loader": "^8.1.0",
    "babel-plugin-inline-json-import": "^0.3.2",
    "babel-plugin-polyfill-corejs3": "^0.2.0",
    "node-sass-import": "^2.0.1",
    "postcss": "^8.1.6",
    "postcss-cli": "^8.2.0",
    "react-is": "^17.0.1",
    "sass-loader": "^10.0.5"
  }
}
  1. In the outer folder, run yarn install
  2. In the framework-entersol folder, run yarn install, yarn clear and yarn build

USING THE FRAMEWORK

To use this framework:

  1. Run yarn link in the repository folder (It will display a message like: Linked "framework-entersol-web")
  2. In Validex frontend, run yarn link "framework-entersol-web"

Your project is now linked with the framework

MAKING CHANGES

After making changes to a component in the framework-entersol project:

  1. In the outer folder, run yarn babel
  2. Your changes will appear automatically in the frontend

UNLINKING PROJECT

Once you have finished to use the project:

  1. In your frontend project, run yarn unlink "framework-entersol-web"
  2. Run yarn install --force

Then, your frontend project will run normally

DEPLOYING CHANGES

Before you will push your changes, you will need to change the package.json's version manually:

{
  "name": "framework-entersol-web",
  "version": "1.4.12", // THIS VERSION NEEDS TO BE CHANGED
  "description": "Framework based on bootstrap 5",
  ...
}
  1. Ensure your changes are committed and pushed to the repository to keep your work up to date.
  2. In your local terminal, add the necessary credentials to authenticate and deploy the project to npm.
  3. To publish the new changes, use the following command: npm publish --access public. This will make the package publicly available on npm.
  4. If you need to see the changes in any environment (development, production, QA, etc.), deploy the frontend environment. Make sure to apply any change that updates the package.json for the framework to reflect the new package version.