Skip to content

Commit 5270100

Browse files
Update project
1 parent 7c5dd2f commit 5270100

File tree

8 files changed

+204
-161
lines changed

8 files changed

+204
-161
lines changed

.github/workflows/check-images.yml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: Check Unused Images
2+
3+
on:
4+
push:
5+
paths:
6+
- '**/*.md'
7+
- '*.png'
8+
- '*.jpg'
9+
- '*.jpeg'
10+
- '*.svg'
11+
- '*.gif'
12+
- 'images/**'
13+
pull_request:
14+
15+
jobs:
16+
check-unused-images:
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v3
20+
21+
- name: Check for unused images
22+
run: |
23+
unused=()
24+
25+
# Find all images in the root and `images/` directory (if it exists)
26+
images=$(find . -maxdepth 1 -type f \( -iname "*.png" -o -iname "*.jpg" -o -iname "*.jpeg" -o -iname "*.svg" -o -iname "*.gif" \) -printf "%P\n")
27+
if [ -d "./images" ]; then
28+
images+=" $(find ./images -type f \( -iname "*.png" -o -iname "*.jpg" -o -iname "*.jpeg" -o -iname "*.svg" -o -iname "*.gif" \) -printf "%P\n")"
29+
fi
30+
31+
# Loop through each image to check if it's referenced in any README files
32+
for img in $images; do
33+
found=false
34+
while IFS= read -r -d '' readme_file; do
35+
if grep -q "!\[.*\](.*$img.*)" "$readme_file"; then
36+
found=true
37+
break
38+
fi
39+
done < <(find . -iname "readme.md" -print0)
40+
41+
if [ "$found" = false ]; then
42+
unused+=("$img")
43+
fi
44+
done
45+
46+
# Check if there are any unused images
47+
if [ ${#unused[@]} -gt 0 ]; then
48+
echo "❌ Unused images found that are not referenced in any README files:"
49+
echo "## Unused Images" >> $GITHUB_STEP_SUMMARY
50+
echo "" >> $GITHUB_STEP_SUMMARY
51+
echo "| Image Name | Path |" >> $GITHUB_STEP_SUMMARY
52+
echo "|------------|------|" >> $GITHUB_STEP_SUMMARY
53+
54+
for img in "${unused[@]}"; do
55+
if [[ -f "./$img" ]]; then
56+
path="./$img"
57+
else
58+
path="./images/$img"
59+
fi
60+
name=$(basename "$img")
61+
echo "$name -> $path"
62+
63+
echo "| $name | $path |" >> $GITHUB_STEP_SUMMARY
64+
done
65+
66+
exit 1
67+
else
68+
echo "✅ No unused images found that are not referenced in README files!"
69+
fi

.github/workflows/check-readme.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Check README links
2+
3+
concurrency:
4+
group: wf-${{github.event.pull_request.number || github.sha}}-${{github.workflow}}
5+
cancel-in-progress: true
6+
7+
on:
8+
pull_request:
9+
push:
10+
branches:
11+
- "[0-9][0-9].[0-9].[0-9]*"
12+
13+
jobs:
14+
link-check:
15+
name: Check README links
16+
runs-on: ubuntu-latest
17+
timeout-minutes: 10
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v4
21+
22+
- name: Check links in README
23+
uses: lycheeverse/lychee-action@v1
24+
with:
25+
args: --verbose --no-progress './**/[Rr][Ee][Aa][Dd][Mm][Ee].md' --exclude-file .lycheeignore
26+
fail: true

.lycheeignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
https://www.devexpress.com/support/examples/survey.xml?*
2+
https://supportcenter.devexpress.com/ticket/create
3+
http*://localhost*

ASP.NET Core/Readme.md

Lines changed: 20 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,32 @@
1-
# ASP.NET Core
1+
# ASP.NET Core DevExtreme Example
22

3-
## Installation
3+
For more information about this example check the [Readme](../README.md).
44

5-
Download the example and use Visual Studio 2019 to open the project.
5+
## Build and Run
66

7-
## Client-side resources and bundling
7+
Prerequisites: .NET 8 SDK, Node.js (for npm/gulp resource bundling).
88

9-
This project uses [NPM](https://www.npmjs.com/) and [Gulp.js](https://gulpjs.com/) to install client-side libraries. The project restores NPM packages before the first build. Then, Gulp bundles required scripts and CSS files into the resulting package during the first and every next build.
9+
Restore and build:
10+
```sh
11+
dotnet restore
12+
dotnet build
13+
```
1014

11-
The resulted bundles will be located in the `wwwroot` folder:
12-
* `css/vendor.css` - a file with all CSS styles.
13-
* `css/icons` and `css/fonts` - folders that contain fonts and icons for DevExtreme themes.
14-
* `js/vendor.js` - a file that contains all scripts.
15+
Run (HTTPS on 5001, HTTP on 5000 by default):
16+
```sh
17+
dotnet run
18+
```
1519

16-
The default bundle includes jQuery, Bootstrap, and DevExtreme.
17-
18-
### Add more 3rd-party libraries for additional features/components
19-
20-
The main logic is located in the the `gulpfile.js` file at the root application level. The file contains two tasks:
21-
22-
* the `add-resouces` task
23-
24-
* copies JavaScript files located in the `scripts` array and adds them to `vendor.js`. The script bundle is moved to `wwwroot\scripts`.
25-
* copies CSS styles located in the `styles` array and merges them into the `styles.css` bundle. Then, this bundle is moved to `wwwroot\styles`
26-
* copies DevExtreme `fonts` and `icons` folders from NPM to `wwwroot\styles`
27-
28-
* the `clean` task removes all previously created files (`vendor.js` and `vendor.css`) and folders (`icons` and `fonts`)
29-
30-
If you need to include more features, you can uncomment one of the following sections:
31-
32-
* Gantt - scripts and styles for [dxGantt](https://js.devexpress.com/DevExtreme/Guide/UI_Components/Gantt/Getting_Started_with_Gantt/).
33-
* Diagram - scripts and styles for [dxDiagram](https://js.devexpress.com/DevExtreme/Guide/UI_Components/Diagram/Getting_Started_with_Diagram/).
34-
* Export - scripts and styles for the exporting feature: [Export Data to Excel](https://js.devexpress.com/DevExtreme/Guide/UI_Components/DataGrid/Getting_Started_with_DataGrid/#Export_Data).
35-
* HtmlEditor - scripts and styles for [dxHtmlEditor](https://js.devexpress.com/DevExtreme/Guide/UI_Components/HtmlEditor/Overview/).
36-
* Full Bundle - scripts and styles for all above mentioned features/components.
37-
38-
## Code
39-
40-
Take a look at the following files of this example to see the required code:
41-
42-
A list of files goes here
43-
44-
## Development server
45-
46-
Use the Visual Studio `Run (F5)` command to run the project.
20+
You can also use Visual Studio: F5 / Ctrl+F5.
4721

4822
## Further help
4923

50-
You can learn more about the ASP.NET Core components' syntax in our documentation: [Concepts](https://docs.devexpress.com/AspNetCore/400574/devextreme-based-controls/concepts/razor-syntax)
51-
The client-side API is based on jQuery [jQuery documentation](https://api.jquery.com/) and described in the following topics:
52-
* [Get and Set Properties](https://js.devexpress.com/DevExtreme/Guide/jQuery_Components/Component_Configuration_Syntax/#Get_and_Set_Properties)
53-
* [Call Methods](https://js.devexpress.com/DevExtreme/Guide/jQuery_Components/Component_Configuration_Syntax/#Call_Methods)
54-
* [Get a UI Component Instance](https://js.devexpress.com/DevExtreme/Guide/jQuery_Components/Component_Configuration_Syntax/#Get_a_UI_Component_Instance)
24+
DevExtreme ASP.NET Core Razor syntax: https://docs.devexpress.com/AspNetCore/400574/devextreme-based-controls/concepts/razor-syntax
25+
Client-side API basics:
26+
* Get/Set properties: https://js.devexpress.com/DevExtreme/Guide/jQuery_Components/Component_Configuration_Syntax/#Get_and_Set_Properties
27+
* Call methods: https://js.devexpress.com/DevExtreme/Guide/jQuery_Components/Component_Configuration_Syntax/#Call_Methods
28+
* Get instance: https://js.devexpress.com/DevExtreme/Guide/jQuery_Components/Component_Configuration_Syntax/#Get_a_UI_Component_Instance
5529

56-
To get more help on DevExtreme submit an issue in the [Support Center](https://www.devexpress.com/Support/Center/Question/Create)
30+
To get more help with DevExtreme, submit a ticket through the [Support Center](https://supportcenter.devexpress.com/ticket/create).
5731

5832

Angular/README.md

Lines changed: 24 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,33 @@
1-
# AngularTest
1+
# Angular DevExtreme Example
22

3-
This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 15.1.3.
3+
For more information about this example check the [Readme](../README.md).
44

5-
## Development server
5+
## Build and Lint
66

7-
Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The application will automatically reload if you change any of the source files.
7+
Install dependencies:
8+
```sh
9+
npm install
10+
```
811

9-
## Code scaffolding
12+
Start dev server:
13+
```sh
14+
npm start
15+
```
16+
Open: http://localhost:4200/
1017

11-
Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.
18+
Build production bundle:
19+
```sh
20+
npm run build
21+
```
1222

13-
## Build
14-
15-
Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory.
16-
17-
## Running unit tests
18-
19-
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
20-
21-
## Running end-to-end tests
22-
23-
Run `ng e2e` to execute the end-to-end tests via a platform of your choice. To use this command, you need to first add a package that implements end-to-end testing capabilities.
23+
Run linter:
24+
```sh
25+
npm run lint
26+
```
2427

2528
## Further help
2629

27-
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://v17.angular.io/cli) page.
28-
To get more help on DevExtreme submit an issue on [GitHub](https://github.com/DevExpress/devextreme/issues) or [Support Center](https://www.devexpress.com/Support/Center/Question/Create)
30+
Angular CLI docs: https://angular.dev/tools/cli
31+
DevExtreme Angular docs: https://js.devexpress.com/Angular/Documentation
32+
33+
To get more help with DevExtreme, submit a ticket through the [Support Center](https://supportcenter.devexpress.com/ticket/create).

React/README.md

Lines changed: 30 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,37 @@
1-
# React + TypeScript + Vite
2-
3-
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
4-
5-
Currently, two official plugins are available:
6-
7-
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react) uses [Babel](https://babeljs.io/) for Fast Refresh
8-
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
9-
10-
## Expanding the ESLint configuration
11-
12-
If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:
13-
14-
```js
15-
export default tseslint.config({
16-
extends: [
17-
// Remove ...tseslint.configs.recommended and replace with this
18-
...tseslint.configs.recommendedTypeChecked,
19-
// Alternatively, use this for stricter rules
20-
...tseslint.configs.strictTypeChecked,
21-
// Optionally, add this for stylistic rules
22-
...tseslint.configs.stylisticTypeChecked,
23-
],
24-
languageOptions: {
25-
// other options...
26-
parserOptions: {
27-
project: ['./tsconfig.node.json', './tsconfig.app.json'],
28-
tsconfigRootDir: import.meta.dirname,
29-
},
30-
},
31-
})
1+
# React + TypeScript + Vite + DevExtreme
2+
3+
For more information about this example check the [Readme](../README.md).
4+
5+
## Build and Lint
6+
7+
Install dependencies:
8+
```sh
9+
npm install
3210
```
3311

34-
You can also install [eslint-plugin-react-x](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-x) and [eslint-plugin-react-dom](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-dom) for React-specific lint rules:
12+
Start dev server:
13+
```sh
14+
npm run dev
15+
```
16+
Open: http://localhost:5173/
3517

36-
```js
37-
// eslint.config.js
38-
import reactX from 'eslint-plugin-react-x'
39-
import reactDom from 'eslint-plugin-react-dom'
18+
Build production bundle:
19+
```sh
20+
npm run build
21+
```
4022

41-
export default tseslint.config({
42-
plugins: {
43-
// Add the react-x and react-dom plugins
44-
'react-x': reactX,
45-
'react-dom': reactDom,
46-
},
47-
rules: {
48-
// other rules...
49-
// Enable its recommended typescript rules
50-
...reactX.configs['recommended-typescript'].rules,
23+
Run linter:
24+
```sh
25+
npm run lint
26+
```
27+
28+
## Further help
29+
30+
React docs: https://react.dev/learn
31+
Vite docs: https://vite.dev/
32+
DevExtreme React docs: https://js.devexpress.com/React/Documentation
33+
34+
To get more help with DevExtreme, submit a ticket through the [Support Center](https://supportcenter.devexpress.com/ticket/create).
5135
...reactDom.configs.recommended.rules,
5236
},
5337
})

Vue/README.md

Lines changed: 16 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,35 @@
1-
# vue-project
1+
# Vue
22

3-
This template should help get you started developing with Vue 3 in Vite.
3+
Take a look at the following files of this example to see the required code:
44

5-
## Recommended IDE Setup
5+
- Your files go here
66

7-
[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
7+
This project was bootstrapped with [Vue CLI](https://cli.vuejs.org/).
88

9-
## Type Support for `.vue` Imports in TS
9+
## Project setup
1010

11-
TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin) to make the TypeScript language service aware of `.vue` types.
12-
13-
If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented a [Take Over Mode](https://github.com/vuejs/language-tools/discussions/471) that is more performant. You can enable it by the following steps:
14-
15-
1. Disable the built-in TypeScript Extension
16-
1) Run `Extensions: Show Built-in Extensions` from VSCode's command palette
17-
2) Find `TypeScript and JavaScript Language Features`, right click and select `Disable (Workspace)`
18-
2. Reload the VSCode window by running `Developer: Reload Window` from the command palette.
19-
20-
## Customize configuration
21-
22-
See [Vite Configuration Reference](https://vite.dev/config/).
23-
24-
## Project Setup
25-
26-
```sh
11+
```
2712
npm install
2813
```
2914

30-
### Compile and Hot-Reload for Development
31-
32-
```sh
33-
npm run dev
15+
### Compiles and hot-reloads for development
16+
```
17+
npm run serve
3418
```
3519

36-
### Type-Check, Compile and Minify for Production
37-
38-
```sh
20+
### Compiles and minifies for production
21+
```
3922
npm run build
4023
```
4124

42-
### Run Unit Tests with [Vitest](https://vitest.dev/)
25+
### Customize configuration
26+
See [Configuration Reference](https://cli.vuejs.org/config/).
4327

44-
```sh
45-
npm run test:unit
46-
```
28+
## Further help
4729

48-
### Lint with [ESLint](https://eslint.org/)
30+
You can learn more about Vue in the [Vue documentation](https://vuejs.org/v2/guide/).
4931

50-
```sh
32+
To get more help on DevExtreme submit an issue on [GitHub](https://github.com/DevExpress/devextreme/issues) or [Support Center](https://www.devexpress.com/Support/Center/Question/Create)
5133
npm run lint
5234
```
5335
### Further help

0 commit comments

Comments
 (0)