Alire - A website project | www.alire.me
Alire is a natural therapeutic company embracing a holistic approach, providing a variety of services including massage, osteopathy, nutrition, and biomagnetism. This website serves as an introduction to the company's philosophy and services.
The primary objective of this project was to experiment with the Astro.js framework as a component-based approach to web development.
- Figma: Creating design and logos 1
- SCSS: Styling with modular and advanced CSS features
- Astro.js: Framework for building the site with components
- Hostinger: The project is hosted on Hostinger. Since Astro doesn't offer a deployment guide specifically for Hostinger, setting up the site required some unexpected challenges.
- Accessible Astro components: Utilized for building accessible and reusable UI components. 2
- Slugify by sindresorhus: Included to handle string conversion for URLs and identifiers. 3
-
First Time Using a Framework
- This project marked my first experience with a framework, moving from traditional static development to component-based architecture with Astro.js.
-
Advanced Git Practices
- Explored branching and rebasing techniques.
- Worked extensively with git logs, including
reflogfor troubleshooting. - Gained experience with merging versus rebasing workflows.
- Practiced resetting files and resolving merge conflicts.
- The focus was on experimentation with Git workflows rather than achieving perfection.
-
Working with Markdown Files
- Gained familiarity with basic Markdown syntax for formatting content, such as headings, lists, links, and images.
- Explored the use of frontmatter to include metadata like titles, descriptions, and configuration options at the beginning of Markdown files.
- Learned how Markdown integrates with Astro to define page-level properties and improve project organization.
- Encountered challenges in formatting complex elements like nested lists and code blocks, but developed a clearer understanding through practice and reference to documentation.
-
Hostinger and Astro Compatibility
-
Hostinger and Astro do not seamlessly integrate. The deployment required custom configurations.
- Creating publish.yml for the build process
- Using the YAML file to generate the
distfolder on the build branch - Hostinger automatically detects the
distfolder for deployment using its CI/CD pipeline.
-
- Adding a "Back to Top" link for better navigation.
- Implementing a "Skip to Main Content" feature to enhance accessibility.
- Integrating light and dark mode for a customizable user experience.
- Adding animations.
- Improve page accessability.
- Modal Focus Issue:
- After closing any of the four modals, the focus returns to the third button instead of the button that opened the modal. This needs to be fixed to ensure proper focus management and accessibility.
-
Create and follow a more robust styling strategy.I started the project without any prior knowledge of Astro or JavaScript frameworks. The process was rocky, and I ended up focusing more on CSS than I had planned originally, which wasn't my objective. In hindsight, I know I should have used Tailwind - it's still on my bucket list!
The basic idea was dust off my Sass knowledge and leverage it to my advantage: make styles modular and reusable for the future. (Hence the many commits related to partial files.) Following this idea all the variables, @font-face etc is served by Sass and imported in each of the layout files. I may have watched too many Kevin Powell videos.
Initially, I used scoped styles, but later I moved everything into the global.css file. This approach is not what Astro recommends, but at that time , it seemed the most reasonable and easiest solution. Since I wasn't using any libraries, I didn't worry about specificity issues during development.
-
Use Javascript library for form validation.
I wrote around 200 lines of Javascript to handle client-side validation and form submission. I utilized the Constraint Validation API and added custom validation rules. As I had used the API before, I was more focused on UX.
The form doesn't preform any validation until the first submission. After that, it provides inline validation to give instant feedback and encourage visitors during the correction phase.
FormSubmit was used for form submission.
I consider the result a win.
-
Use pre-made componenents and learn from them.
They are incredibly useful and solve problems that I wasn't aware before.
- The overall look of the website.
- PageSpeed Scores
- hero-image.jpg : Photo by Kaboompics.com
- form-background.jpg : Photo by RDNE Stock Project
- cta-image-01.jpg : Photo by Monika Grabowska
- cta-image-02.jpg : Photo by Sean Stratton
- cta-image-03.jpg : Photo by Miklas Ohlrogge
- cta-image-02.jpg : Photo by Caju Gomes
- nutrition-overlay.jpg: Photo by Adonyi Gábor
- massage-overlay.jpg: Photo by Anna Tarazevich
- osteopathy-overlay.jpg: Photo by Yan Krukau
- biomagnet-overlay.jpg: Photo by David Bartus
- post-1.jpg: Photo by Tima Miroshnichenko
- post-2.jpg: Photo by Serhii Kalyn
- post-3.jpg: Photo by Thought Catalog
- post-4.jpg: Photo by Nikko Macaspac
- post-5.jpg: Photo by Lukas
- 404-background.avif: Photo by Michael Judkins



