Skip to content

Digital educational content in the chemical industry πŸ”¬

Notifications You must be signed in to change notification settings

denpiligrim/nhmt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

45 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

NHMT - ΠΏΡ€ΠΎΠ΅ΠΊΡ‚ для сборки ЦОК

Π‘Π΄Π΅Π»Π°Π½ΠΎ Ρ€Π°Π·Ρ€Π°Π±ΠΎΡ‚Ρ‡ΠΈΠΊΠΎΠΌ @denpiligrim

ЗапускаСм Π³Π΅Π½Π΅Ρ€Π°Ρ†ΠΈΡŽ манифСста

Π’ tsconfig.json опрСдСляСм ΠΏΠ°Ρ€Π°ΠΌΠ΅Ρ‚Ρ€:

  {
    "compilerOptions": {
      "module": "CommonJS"
    }
  }

Π’ package.json опрСдСляСм ΠΏΠ°Ρ€Π°ΠΌΠ΅Ρ‚Ρ€:

  {
    "type": "commonjs"
  }

ЗапускаСм скрипт ΠΊΠΎΠΌΠ°Π½Π΄ΠΎΠΉ npm run manifest ΠΈΠ»ΠΈ ts-node generateManifest.ts

Установка cwebp

Π¨Π°Π³ 1: Π‘ΠΊΠ°Ρ‡Π°ΠΉΡ‚Π΅ WebP Tools

  1. ΠŸΠ΅Ρ€Π΅ΠΉΠ΄ΠΈΡ‚Π΅ Π½Π° страницу WebP ΠΎΡ‚ Google.
  2. Π‘ΠΊΠ°Ρ‡Π°ΠΉΡ‚Π΅ WebP Utilities for Windows, ΠΎΠ±Ρ‹Ρ‡Π½ΠΎ Π°Ρ€Ρ…ΠΈΠ² называСтся libwebp-x.x.x-windows.zip, Π³Π΄Π΅ x.x.x β€” вСрсия.
  3. РаспакуйтС скачанный Π°Ρ€Ρ…ΠΈΠ² Π² ΡƒΠ΄ΠΎΠ±Π½ΠΎΠ΅ мСсто, Π½Π°ΠΏΡ€ΠΈΠΌΠ΅Ρ€, Π² ΠΏΠ°ΠΏΠΊΡƒ C:\webp.

Π¨Π°Π³ 2: Настройка ΠΏΠ΅Ρ€Π΅ΠΌΠ΅Π½Π½ΠΎΠΉ окруТСния PATH (рСкомСндуСтся)

Π”ΠΎΠ±Π°Π²ΡŒΡ‚Π΅ ΠΏΡƒΡ‚ΡŒ ΠΊ cwebp.exe Π² ΠΏΠ΅Ρ€Π΅ΠΌΠ΅Π½Π½ΡƒΡŽ окруТСния PATH, Ρ‡Ρ‚ΠΎΠ±Ρ‹ ΠΈΠΌΠ΅Ρ‚ΡŒ Π²ΠΎΠ·ΠΌΠΎΠΆΠ½ΠΎΡΡ‚ΡŒ Π·Π°ΠΏΡƒΡΠΊΠ°Ρ‚ΡŒ Π΅Π³ΠΎ ΠΈΠ· любой ΠΏΠ°ΠΏΠΊΠΈ.

  1. ΠžΡ‚ΠΊΡ€ΠΎΠΉΡ‚Π΅ ΠŸΠ°Ρ€Π°ΠΌΠ΅Ρ‚Ρ€Ρ‹ > БистСма > О систСмС > Π”ΠΎΠΏΠΎΠ»Π½ΠΈΡ‚Π΅Π»ΡŒΠ½Ρ‹Π΅ ΠΏΠ°Ρ€Π°ΠΌΠ΅Ρ‚Ρ€Ρ‹ систСмы.
  2. Π’ Ρ€Π°Π·Π΄Π΅Π»Π΅ ΠŸΠ΅Ρ€Π΅ΠΌΠ΅Π½Π½Ρ‹Π΅ срСды Π²Ρ‹Π±Π΅Ρ€ΠΈΡ‚Π΅ ΠΏΠ΅Ρ€Π΅ΠΌΠ΅Π½Π½ΡƒΡŽ Path ΠΈ Π½Π°ΠΆΠΌΠΈΡ‚Π΅ Π˜Π·ΠΌΠ΅Π½ΠΈΡ‚ΡŒ.
  3. НаТмитС Π‘ΠΎΠ·Π΄Π°Ρ‚ΡŒ ΠΈ ΡƒΠΊΠ°ΠΆΠΈΡ‚Π΅ ΠΏΡƒΡ‚ΡŒ ΠΊ ΠΏΠ°ΠΏΠΊΠ΅, Π³Π΄Π΅ находится cwebp.exe. НапримСр, C:\webp\bin.
  4. Π‘ΠΎΡ…Ρ€Π°Π½ΠΈΡ‚Π΅ измСнСния ΠΈ Π·Π°ΠΊΡ€ΠΎΠΉΡ‚Π΅ всС ΠΎΠΊΠ½Π°.

Π’Π΅ΠΏΠ΅Ρ€ΡŒ cwebp доступСн для выполнСния Π² любой Π΄ΠΈΡ€Π΅ΠΊΡ‚ΠΎΡ€ΠΈΠΈ.

Π¨Π°Π³ 3: ΠŸΡ€ΠΎΠ²Π΅Ρ€ΠΊΠ° установки

ΠžΡ‚ΠΊΡ€ΠΎΠΉΡ‚Π΅ ΠšΠΎΠΌΠ°Π½Π΄Π½ΡƒΡŽ строку ΠΈ Π²Ρ‹ΠΏΠΎΠ»Π½ΠΈΡ‚Π΅ ΠΊΠΎΠΌΠ°Π½Π΄Ρƒ:

cwebp -version

ΠšΠΎΠ½Π²Π΅Ρ€Ρ‚Π°Ρ†ΠΈΡ ΠΈΠ·ΠΎΠ±Ρ€Π°ΠΆΠ΅Π½ΠΈΠΉ Π² webp

Get-ChildItem -File | Where-Object { $_.Extension -match '\.(webp|jpg|jpeg|JPG|PNG|png|GIF|gif)$' } | ForEach-Object { cwebp -q 90 $_.FullName -o "$($_.DirectoryName)\$($_.BaseName).webp" }

React + TypeScript + Vite

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.

Currently, two official plugins are available:

Expanding the ESLint configuration

If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:

  • Configure the top-level parserOptions property like this:
   parserOptions: {
    ecmaVersion: 'latest',
    sourceType: 'module',
    project: ['./tsconfig.json', './tsconfig.node.json'],
    tsconfigRootDir: __dirname,
   },
  • Replace plugin:@typescript-eslint/recommended to plugin:@typescript-eslint/recommended-type-checked or plugin:@typescript-eslint/strict-type-checked
  • Optionally add plugin:@typescript-eslint/stylistic-type-checked
  • Install eslint-plugin-react and add plugin:react/recommended & plugin:react/jsx-runtime to the extends list

About

Digital educational content in the chemical industry πŸ”¬

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages