├── LICENSE
├── README.md
├── config.json
├── index.html
├── mastowall-favicon.png
├── script.js
└── styles.css
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2023 Ralf Stockmann
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Mastowall 1.1
2 |
3 | Mastowall is a social wall application that displays posts from the [Mastodon](https://joinmastodon.org/) social network based on specified hashtags. It was written entirely by [ChatGPT4](https://openai.com/product/gpt-4), guided only by text prompts.
4 |
5 |
6 |
7 |
8 | Try it live: [Mastowall for the WWDC conference](https://rstockm.github.io/mastowall/?hashtags=wwdc,wwdc23,apple&server=https://mastodon.social))
9 |
10 | Use your own hashtags and server:
11 |
12 |
13 |
14 | JSON config file:
15 |
16 |
17 |
18 |
19 |
20 | ## Features
21 |
22 | - **Display Posts:** The app fetches and displays posts from Mastodon based on the hashtags provided in the URL. If no hashtags are provided, it presents a form to enter up to three hashtags.
23 |
24 | - **Custom Mastodon Server:** Allows users to specify a Mastodon server URL from which to fetch posts.
25 |
26 | - **Real-Time Updates:** Mastowall updates the posts every 10 seconds, ensuring that the content displayed is always current.
27 |
28 | - **Relative Timestamps:** The timestamps of the posts are displayed relative to the current time, and are updated every minute to reflect the passing time.
29 |
30 | - **Masonry Grid Layout:** The posts are displayed in a masonry grid layout for a visually pleasing experience.
31 |
32 | - **Responsive Design:** The layout adjusts according to the screen size for better readability on different devices.
33 |
34 | - **Navbar Hashtag Navigation:** Clicking on the hashtags in the navbar takes you to the form screen, allowing you to change the existing hashtags easily.
35 |
36 | - **Navbar Color Customization:** The color of the navigation bar can now be customized via the `config.json` file.
37 |
38 | - **Including Replies:** By default, replies are excluded from the wall. However, this behavior can be changed by setting includeReplies to true in the `config.json` file.
39 |
40 | ## Technology Stack
41 |
42 | Mastowall is built using the following technologies:
43 |
44 | - **HTML, CSS, and JavaScript**: For structuring, styling, and functionality.
45 |
46 | - **[jQuery](https://jquery.com/)**: A fast, small, and feature-rich JavaScript library.
47 |
48 | - **[Masonry](https://masonry.desandro.com/)**: A JavaScript grid layout library.
49 |
50 | - **[Bootstrap](https://getbootstrap.com/)**: A popular CSS framework for responsive, mobile-first front-end web development.
51 |
52 | - **[DOMPurify](https://github.com/cure53/DOMPurify)**: Library for sanitizing HTML input, which should prevent the vast majority of malicious input from being rendered
53 |
54 | ## Usage
55 |
56 | 1. Load the application in a web browser. If no hashtags are specified in the URL, you will be presented with a form to enter up to three hashtags and a server URL.
57 |
58 | 2. After entering your hashtags and clicking 'Reload', the application will fetch and display posts from the specified Mastodon server that include those hashtags.
59 |
60 | 3. The displayed posts will update every 10 seconds. The relative timestamps will also update every minute.
61 |
62 | 4. To change the hashtags, click on them in the navbar to go back to the form screen.
63 |
64 | ## Sharing via URL
65 |
66 | Mastowall supports URL parameters to easily share specific hashtag configurations and the Mastodon server. Simply append the desired hashtags and the server URL to the URL following this format: `?hashtags=hashtag1,hashtag2,hashtag3&server=serverUrl`
67 |
68 | Enjoy using Mastowall!
69 |
70 | ## AI-Guided Development: A Proof of Concept
71 |
72 | Mastowall may serve as an example of how artificial intelligence can aid and accelerate the software development process. The development of this version of the app was guided by OpenAI's GPT-4, a large language model.
73 |
74 | In this process, the human developer posed problems, asked questions, and described the desired features and functionalities of the application. GPT-4 then provided solutions, answered queries, generated code snippets, and suggested optimal ways to implement these features.
75 |
76 | Every single line of code was written by ChatGPT4.
77 | Including this README.
78 |
--------------------------------------------------------------------------------
/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "navbarBrandText": "Mastowall 1.2 - written by ChatGPT4 - Prompting: Ralf Stockmann (rstockm)",
3 | "defaultServerUrl": "https://mastodon.social",
4 | "navbarColor": "#333355",
5 | "includeReplies": true
6 | }
7 |
--------------------------------------------------------------------------------
/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |