Skip to main content

A simple web framework.

Project description

sitepy

A simple web framework for Python.

Installation

You can install sitepy with pip:

pip install sitepy

Usage

Here's a basic example of a sitepy application:

from sitepy import sitepy

app = sitepy()

@app.route("/", methods=['GET', 'POST'])
def index():
    return "Hello, world!"

if __name__ == "__main__":
    app.run()

This will start a server on localhost:8080 and respond with "Hello, world!" to GET and POST requests at the root URL.

Features

  • Simple routing: Use the @app.route decorator to define routes.

  • Middleware support: Use app.use to add middleware functions.

  • Static file serving: Files in the static directory are served at /static.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

Apache

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sitepy-0.4.6.tar.gz (14.8 kB view details)

Uploaded Source

Built Distribution

sitepy-0.4.6-py3-none-any.whl (14.7 kB view details)

Uploaded Python 3

File details

Details for the file sitepy-0.4.6.tar.gz.

File metadata

  • Download URL: sitepy-0.4.6.tar.gz
  • Upload date:
  • Size: 14.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for sitepy-0.4.6.tar.gz
Algorithm Hash digest
SHA256 a2cbccc226f9348c5327c61941b2407c2c93fefb3903f057389379113f09c47e
MD5 7c77b63cff221cd6f0c757c32cdbe269
BLAKE2b-256 1ea1f9de8da2ab98d76a806d43de180d6fa7f3c13f7d4f9c9c5e1e4359fc1e3f

See more details on using hashes here.

File details

Details for the file sitepy-0.4.6-py3-none-any.whl.

File metadata

  • Download URL: sitepy-0.4.6-py3-none-any.whl
  • Upload date:
  • Size: 14.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for sitepy-0.4.6-py3-none-any.whl
Algorithm Hash digest
SHA256 4d68c773485d534c566f0a3f5637efa3498262db6c6035ac2bc0f4681e2deec7
MD5 f98ff8881581a4fd0e6e1f040578ccd5
BLAKE2b-256 a89a575c4f88ff40d975c1ec95f891f4f05a73a5ac9a56af7360def9034d9b59

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page