Thank you for your interest in contributing to the Noorle Plugin Examples repository! These examples help developers learn how to build plugins for the Noorle platform using WebAssembly and various programming languages.
We welcome contributions in several areas:
- Implement practical, real-world use cases
- Demonstrate unique WASI capabilities or patterns
- Show integration with popular APIs or services
- Add implementations of existing plugins in new languages
- Ensure consistency with other language versions
- Follow language-specific best practices
- Bug fixes and performance optimizations
- Better error handling
- Code clarity and documentation improvements
- Update dependencies to latest stable versions
- Improve READMEs with clearer explanations
- Add inline code comments for complex logic
- Create tutorials or guides
- Fix typos and improve clarity
# Fork the repository on GitHub, then:
git clone https://github.com/YOUR_USERNAME/plugin-examples
cd plugin-examplesgit checkout -b feature/your-feature-name
# or
git checkout -b fix/issue-descriptionFollow the project structure and coding standards (see below).
# Build the plugin
noorle plugin build
# Test with wasmtime (example)
wasmtime run --wasi http \
--invoke 'your-function("params")' dist/plugin.wasmgit add .
git commit -m "feat: add new currency converter plugin"
# or
git commit -m "fix: handle network timeout in weather plugin"Follow conventional commit messages:
feat:for new featuresfix:for bug fixesdocs:for documentation changesrefactor:for code refactoringtest:for test additions/changeschore:for maintenance tasks
git push origin your-branch-nameThen create a Pull Request on GitHub.
language/plugin-name/
├── src/ or app.* # Main implementation file(s)
├── wit/
│ └── world.wit # WIT interface definition
├── noorle.yaml # Plugin configuration
├── build.sh # Build script
├── .env.example # Environment template (if needed)
├── README.md # Comprehensive documentation
└── dist/ # Build output (git ignored)
Must specify:
- Plugin metadata (name, version, description)
- WASI permissions required
- Environment variables used
Must include:
- Clear function signatures
- Descriptive parameter names
- Result types for error handling
- Documentation comments
Must contain:
- Plugin overview and purpose
- Features list
- Architecture explanation
- Build and deployment instructions
- API reference with examples
- Learning outcomes
Must:
- Be executable (
chmod +x build.sh) - Handle dependencies installation
- Compile to WASM component
- Output to
dist/plugin.wasm
- Security First: Never hardcode secrets or API keys
- Error Handling: Always return meaningful error messages
- Documentation: Comment complex logic and algorithms
- Testing: Include test commands in README
- Idiomatic Code: Follow language-specific conventions
- Use
cargo fmtandcargo clippy - Prefer
anyhowfor error handling in examples - Use
wakifor HTTP in WASI environments - Target
wasm32-wasip2
- Use
gofmtfor formatting - Follow standard Go project layout
- Use TinyGo for compilation
- Target
wasip2
- Follow PEP 8 style guide
- Use type hints where appropriate
- Use
componentize-pyfor WASM compilation
- Use ES modules
- Include
package-lock.json - For TypeScript, use strict mode
- Use ComponentizeJS for WASM compilation
- Should demonstrate real-world functionality
- Avoid duplicating existing examples
- Consider common developer needs
- Start with one language implementation
- Focus on clean, understandable code
- Include proper error handling
- Explain why this example matters
- Document all functions and parameters
- Include usage examples
- Add troubleshooting section if needed
# Build
noorle plugin build
# Test each exported function
wasmtime run --wasi http \
--invoke 'function-name("params")' dist/plugin.wasm
# Verify error cases
# Test with invalid inputs
# Check timeout handlingUpdate the root README.md to include your new example in the "Available Examples" section.
Use a clear, descriptive title:
- ✅ "Add QR code generator plugin in Rust"
- ✅ "Fix timeout handling in weather plugin"
- ❌ "Updates"
- ❌ "Fixed stuff"
Include:
- What: Brief description of changes
- Why: Motivation and use case
- How: Technical approach taken
- Testing: How you tested the changes
- Screenshots: If applicable (for output examples)
## What
Added a new PDF generator plugin that creates PDFs from Markdown.
## Why
Many developers need to generate PDFs from structured content.
This example shows how to handle binary output from WASM plugins.
## How
- Uses `wasi-pdf` library for PDF generation
- Implements streaming for large documents
- Returns base64-encoded PDF data
## Testing
- Tested with various Markdown inputs
- Verified PDF output in multiple viewers
- Tested error handling with malformed input- Automated Checks: Ensure your code builds successfully
- Code Review: Maintainers will review for:
- Code quality and clarity
- Security best practices
- Consistency with existing examples
- Documentation completeness
- Testing: Reviewers may test your plugin locally
- Feedback: Address any requested changes
- Merge: Once approved, your PR will be merged
- Questions: Open an issue with the "question" label
- Bugs: Open an issue with reproduction steps
- Ideas: Open an issue with the "enhancement" label
- Discussions: Use GitHub Discussions for general topics
By contributing to this repository, you agree that your contributions will be licensed under the MIT License with additional terms for Noorle Platform integration as specified in the LICENSE file.
Your contributions may be used by Noorle for:
- Platform documentation
- Tutorial content
- Promotional materials
- Integration into Noorle services
We value all contributions! Contributors will be:
- Listed in release notes
- Mentioned in commit messages
- Credited in documentation where applicable
- Be respectful and inclusive
- Welcome newcomers and help them learn
- Accept constructive criticism gracefully
- Focus on what's best for the community
- Show empathy towards others
- Harassment or discrimination
- Trolling or insulting comments
- Publishing others' private information
- Other unprofessional conduct
Your contributions help make Noorle plugin development accessible to developers worldwide. We appreciate your time and effort in improving these examples!
Happy coding! 🚀