Skip to content

Commit

Permalink
Copy over from responsive-image-loader
Browse files Browse the repository at this point in the history
  • Loading branch information
IlCallo committed Mar 15, 2022
0 parents commit 97f6427
Show file tree
Hide file tree
Showing 56 changed files with 8,320 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/dist
/test/coverage
.eslintrc.js
webpack.config.js
47 changes: 47 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
module.exports = {
root: true,

parserOptions: {
parser: '@typescript-eslint/parser',
project: './tsconfig.json',
sourceType: 'module',
},

env: {
node: true,
},

// Rules order is important, please avoid shuffling them
extends: [
// Base ESLint recommended rules
'eslint:recommended',

// ESLint typescript rules
// See https://github.com/typescript-eslint/typescript-eslint/tree/master/packages/eslint-plugin#usage
'plugin:@typescript-eslint/recommended',
'plugin:@typescript-eslint/recommended-requiring-type-checking',

// Usage with Prettier, provided by 'eslint-config-prettier'.
// https://github.com/typescript-eslint/typescript-eslint/tree/master/packages/eslint-plugin#usage-with-prettier
'prettier',
],

plugins: [
// Required to apply rules which need type information
'@typescript-eslint',
// Prettier has not been included as plugin to avoid performance impact
// See https://github.com/typescript-eslint/typescript-eslint/issues/389#issuecomment-509292674
// Add it as an extension for your IDE
],

// add your custom rules here
rules: {
'prefer-promise-reject-errors': 'off',
quotes: ['warn', 'single'],

// allow console.log during development only
'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
// allow debugger during development only
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
},
};
38 changes: 38 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: bug
assignees: ''

---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Desktop (please complete the following information):**
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]

**Smartphone (please complete the following information):**
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]

**Additional context**
Add any other context about the problem here.
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: enhancement
assignees: ''

---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
node_modules
/dist
/test/coverage
yarn-debug.log*
yarn-error.log*

# Editor directories and files
.idea
5 changes: 5 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"singleQuote": true,
"semi": true,
"trailingComma": "all"
}
12 changes: 12 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"recommendations": [
"esbenp.prettier-vscode",
"dbaeumer.vscode-eslint",
"eamodio.gitlens"
],
"unwantedRecommendations": [
"hookyqr.beautify",
"dbaeumer.jshint",
"ms-vscode.vscode-typescript-tslint-plugin"
]
}
6 changes: 6 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"editor.formatOnSave": true,
"editor.formatOnPaste": true,
"eslint.validate": ["javascript", "javascriptreact", "typescript"],
"typescript.tsdk": "node_modules/typescript/lib"
}
70 changes: 70 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# Changelog

## 0.6.0

- Chore: update deps
- Refactor: replace unmaintained `request` with `got` into `thumbor-docker` transformer
- Refactor: remove old `thumbor` transformer implementation, rename `thumbor-docker` to `thumbor`

## 0.5.0

- Feat: add background images fallback hook for SSR/SSG builds

## 0.4.2

- Chore: update deps
- Docs: explain usage when executed into Node environment (eg. Quasar SSR)

## 0.4.1

- Docs: fix changelog
- Fix: allow usage on every OS

## 0.4.0

- Chore: update deps
- Feat: add `thumbor-docker` transformer
- Chore: deprecate `thumbor` transformer
- Feat: support Windows and Mac using docker to run Thumbor

## 0.3.3

- Chore: update deps
- Fix: correctly throw when property options are malformed
- Docs: clarify usage of properties with multiple options and viewports
- Tests(parsing): cover properties/options/viewports parsing

## 0.3.2

- Chore: update deps

## 0.3.1

- Feat: make `background-image` optimization support web components slots systems

## 0.3.0

- Feat: support `background-image` optimization

## 0.2.0

- Fix: avoid `sizes="NaNvm"` when AD is disabled and RS is enabled
- Feat: move aliases and size management to global level, change properties syntax
- Feat: allow size as absolute value in pixels
- Perf(RS): avoid processing intervals where source images are too small

## 0.1.5

- Fix: 'path' option is now correctly taken into consideration

## 0.1.4

- Feat: loose up class management RegExps

## 0.1.3

- Feat: class management on enhanced `<img>`s and wrapping `<picture>`

## 0.1.2

- First stable release
Loading

0 comments on commit 97f6427

Please sign in to comment.