Skip to content

Commit 951b848

Browse files
committed
review changes
1 parent 83bb34a commit 951b848

12 files changed

Lines changed: 82 additions & 222 deletions

File tree

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@ jobs:
2525
run: npm ci
2626

2727
- name: Run linters
28-
run: npm run lint
28+
run: make lint

.prettierrc.json

Lines changed: 0 additions & 13 deletions
This file was deleted.

Makefile

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,22 @@
1-
default: setup clean lintfix serve
1+
default: setup clean lintfix dev
22

33
setup:
44
npm ci
55
bundle check || bundle
66
make update
77

8+
dev:
9+
npm run dev
10+
11+
build:
12+
npm run build
13+
14+
preview:
15+
npm run preview
16+
17+
build-full:
18+
npm run build:full
19+
820
lint:
921
npm run lint
1022

@@ -18,6 +30,3 @@ clean:
1830
update:
1931
bundle update html2rss-configs
2032
bin/data-update
21-
22-
serve: setup
23-
bundle exec jekyll s --drafts --trace

README.md

Lines changed: 32 additions & 170 deletions
Original file line numberDiff line numberDiff line change
@@ -1,187 +1,49 @@
1-
# html2rss Documentation
1+
# html2rss.github.io
22

3-
The official documentation website for html2rss, built with Astro Starlight for modern performance and developer experience.
3+
This repository hosts the documentation and website for `html2rss`, a tool for creating RSS feeds from any
4+
website.
45

5-
## 🚀 Features
6-
7-
- **Modern Documentation**: Built with Astro Starlight for better performance and developer experience
8-
- **Interactive Feed Directory**: Fully functional with search, filtering, and parameter configuration
9-
- **Progressive Enhancement**: Works without JavaScript, enhanced with Alpine.js
10-
- **Dark Theme**: Integrated with Starlight's theme system
11-
- **GitHub Integration**: Edit links and social links
12-
- **Analytics**: GoatCounter integration
13-
- **SEO Optimized**: Meta tags, sitemap, and search indexing
14-
15-
## 📁 Project Structure
16-
17-
```
18-
html2rss.github.io/
19-
├── src/
20-
│ ├── content/docs/ # Documentation content (MDX)
21-
│ ├── components/ # Astro components
22-
│ │ └── FeedDirectory.astro # Interactive feed directory
23-
│ ├── data/ # Data files
24-
│ │ ├── configs.json # Generated feed configurations
25-
│ │ └── loadConfigs.ts # Data loader
26-
│ └── assets/ # Static assets
27-
├── bin/
28-
│ └── data-update # Script to update feed data
29-
├── public/ # Public assets
30-
├── .github/workflows/ # CI/CD workflows
31-
└── Gemfile # Ruby dependencies for data updates
32-
```
33-
34-
## 🛠️ Development
6+
## 🚀 Getting Started (Developers)
357

368
### Prerequisites
379

38-
- Node.js 22+
39-
- Ruby 3.3+
40-
- npm/yarn
41-
42-
### Setup
43-
44-
1. **Install Node.js dependencies:**
45-
```bash
46-
npm install
47-
```
48-
49-
2. **Install Ruby dependencies:**
50-
```bash
51-
bundle install
52-
```
53-
54-
3. **Update feed data:**
55-
```bash
56-
npm run update-data
57-
```
58-
59-
4. **Start development server:**
60-
```bash
61-
npm run dev
62-
```
63-
64-
### Available Scripts
65-
66-
- `npm run dev` - Start development server
67-
- `npm run build` - Build for production
68-
- `npm run preview` - Preview production build
69-
- `npm run update-data` - Update feed configurations from html2rss-configs
70-
- `npm run build:full` - Update data and build
71-
72-
## 📊 Data Management
73-
74-
The feed directory data is automatically generated from the `html2rss-configs` gem:
75-
76-
1. **Source**: `html2rss-configs` gem (latest commit from GitHub)
77-
2. **Generation**: `bin/data-update` script processes the gem's configs
78-
3. **Output**: `src/data/configs.json` (clean JSON format)
79-
4. **Usage**: Loaded by `src/data/loadConfigs.ts` in the FeedDirectory component
80-
81-
### Data Update Process
82-
83-
The `bin/data-update` script:
84-
- Fetches all config files from the `html2rss-configs` gem
85-
- Extracts metadata (domain, name, parameters, etc.)
86-
- Converts to clean JSON format (no parsing issues)
87-
- Generates `src/data/configs.json`
88-
89-
## 🚀 Deployment
10+
- Node.js (for Astro)
11+
- Ruby (for data updates)
9012

91-
### GitHub Pages (CI/CD)
92-
93-
The site is automatically deployed via GitHub Actions:
94-
95-
1. **Trigger**: Push to `main` branch
96-
2. **Process**:
97-
- Install Ruby dependencies
98-
- Run `bin/data-update` to update feed data
99-
- Install Node.js dependencies
100-
- Build Astro site
101-
- Deploy to GitHub Pages
102-
103-
### Manual Deployment
13+
### Quick Setup
10414

10515
```bash
106-
# Update data and build
107-
npm run build:full
108-
109-
# Deploy the dist/ folder to your hosting provider
16+
# Install dependencies and start development server
17+
make setup
11018
```
11119

112-
## 🔧 Configuration
113-
114-
### Astro Configuration
115-
116-
Key settings in `astro.config.mjs`:
117-
- Site URL and base path
118-
- Starlight integration with custom head elements
119-
- GitHub social links and edit URLs
120-
- Sidebar navigation structure
121-
122-
### Feed Directory
123-
124-
The interactive Feed Directory (`src/components/FeedDirectory.astro`):
125-
- Uses Alpine.js for interactivity
126-
- Loads data from `src/data/configs.yml`
127-
- Provides search and filtering
128-
- Shows parameter forms for dynamic feeds
129-
- Generates RSS URLs and GitHub edit links
130-
131-
## 📝 Content Migration
132-
133-
All content has been migrated from Jekyll to Astro Starlight:
134-
135-
- **Markdown → MDX**: Converted all `.md` files to `.mdx`
136-
- **Frontmatter**: Updated to Starlight format
137-
- **URLs**: Updated relative links
138-
- **Images**: Migrated to `public/assets/images/`
139-
- **Components**: Recreated Jekyll components as Astro components
140-
141-
## 🎨 Styling
142-
143-
- **Theme**: Uses Starlight's built-in theme system
144-
- **Colors**: HSL color variables for dark/light mode compatibility
145-
- **Components**: Custom CSS for Feed Directory integrated with Starlight
146-
- **Responsive**: Mobile-friendly design
147-
148-
## 🔍 Search
149-
150-
- **Engine**: Pagefind (integrated with Starlight)
151-
- **Indexing**: Automatic during build
152-
- **Features**: Full-text search across all documentation
153-
154-
## 📈 Analytics
155-
156-
- **Provider**: GoatCounter
157-
- **Integration**: Script added to `astro.config.mjs`
158-
- **Privacy**: No cookies, GDPR compliant
159-
160-
## 🐛 Troubleshooting
161-
162-
### Common Issues
20+
### Available Commands
16321

164-
1. **Data not loading**: Run `npm run update-data` to regenerate configs
165-
2. **Build errors**: Check for JSON syntax issues in generated data
166-
3. **Styling issues**: Ensure CSS uses Starlight's color variables
22+
- `make setup` - Install dependencies and start dev server
23+
- `make dev` - Start Astro development server
24+
- `make build` - Build for production
25+
- `make preview` - Preview production build
26+
- `make build-full` - Update data and build for production
27+
- `make lintfix` - Fix code formatting
28+
- `make update` - Update feed data
16729

168-
### Development Tips
30+
## 🌐 Community & Resources
16931

170-
- Use `npm run build:full` to test the complete build process
171-
- Check `src/data/configs.json` for data issues
172-
- Use browser dev tools to debug Alpine.js components
32+
| Resource | Description | Link |
33+
| ------------------------------------- | ----------------------------------------------------------- | ------------------------------------------------------------------ |
34+
| **📚 Documentation & Feed Directory** | Complete guides, tutorials, and browse 100+ pre-built feeds | [html2rss.github.io](https://html2rss.github.io) |
35+
| **💬 Community Discussions** | Get help, share ideas, and connect with other users | [GitHub Discussions](https://github.com/orgs/html2rss/discussions) |
36+
| **📋 Project Board** | Track development progress and upcoming features | [View Project Board](https://github.com/orgs/html2rss/projects) |
37+
| **💖 Support Development** | Help fund ongoing development and maintenance | [Sponsor on GitHub](https://github.com/sponsors/gildesmarais) |
17338

174-
## 📚 Migration Notes
39+
**Quick Start Options:**
17540

176-
This migration preserves all functionality from the original Jekyll site:
41+
- **New to RSS?** → Start with the [web application](https://html2rss.github.io/web-application)
42+
- **Ruby Developer?** → Check out the [Ruby gem documentation](https://html2rss.github.io/ruby-gem)
43+
- **Need a specific feed?** → Browse the [feed directory](https://html2rss.github.io/feed-directory)
44+
- **Want to contribute?** → See our [contributing guide](https://html2rss.github.io/get-involved/contributing)
17745

178-
- ✅ All content migrated
179-
- ✅ Feed Directory fully functional
180-
- ✅ Search and navigation working
181-
- ✅ GitHub integration maintained
182-
- ✅ Analytics preserved
183-
- ✅ SEO optimization maintained
184-
- ✅ Progressive enhancement working
185-
- ✅ Dark theme support
46+
## Contributing
18647

187-
The new Astro Starlight version provides better performance, modern tooling, and improved developer experience while maintaining full backward compatibility.
48+
Contributions are welcome! See our [Get Involved page](https://html2rss.github.io/get-involved) for details on
49+
discussions, reporting issues, and contributing.

bin/data-update

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ end
5959
config_file = File.join(__dir__, '..', 'src/data/configs.json')
6060
FileUtils.touch config_file
6161

62-
# Convert to JSON (no Ruby-specific tags to clean up)
6362
json_content = JSON.pretty_generate(output)
6463

6564
File.write(config_file, json_content)

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
"astro": "astro",
1111
"update-data": "ruby bin/data-update",
1212
"build:full": "npm run update-data && npm run build",
13-
"lint": "prettier --check 'src/**/*.{astro,js,ts,jsx,tsx,css,scss,md,mdx}'",
14-
"lintfix": "prettier --write 'src/**/*.{astro,js,ts,jsx,tsx,css,scss,md,mdx}'"
13+
"lint": "prettier --check .",
14+
"lintfix": "prettier --write ."
1515
},
1616
"dependencies": {
1717
"@astrojs/starlight": "^0.35.3",

prettier.config.js

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
/** @type {import("prettier").Config} */
2+
export default {
3+
// Global settings
4+
printWidth: 110,
5+
singleQuote: false,
6+
trailingComma: 'all',
7+
plugins: ['prettier-plugin-astro'],
8+
9+
// File-specific overrides
10+
overrides: [
11+
{
12+
// Astro files need special parser
13+
files: '*.astro',
14+
options: {
15+
parser: 'astro',
16+
},
17+
},
18+
{
19+
// Markdown and prose files should preserve natural line breaks
20+
files: '*.{html,md,mdx}',
21+
options: {
22+
proseWrap: 'preserve', // Don't force rewrapping of prose content
23+
},
24+
},
25+
{
26+
// JavaScript/TypeScript files use single quotes and ES5 trailing commas
27+
files: '*.{js,ts,jsx,tsx}',
28+
options: {
29+
singleQuote: true,
30+
trailingComma: 'es5',
31+
},
32+
},
33+
],
34+
};

src/content/docs/configs.mdx

Lines changed: 0 additions & 8 deletions
This file was deleted.

src/content/docs/ruby-gem/how-to/advanced-features.mdx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ Optimize requests with appropriate headers:
5959
headers:
6060
Accept: "text/html,application/xhtml+xml" # Avoid JSON if not needed
6161
Accept-Encoding: "gzip, deflate" # Enable compression
62-
User-Agent: "html2rss/1.0" # Identify your requests
6362
```
6463

6564
## Monitoring and Debugging

src/content/docs/ruby-gem/how-to/index.mdx

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)