Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Various HTML fixes #76

Open
wants to merge 23 commits into
base: main
Choose a base branch
from

Conversation

chrisdenman
Copy link
Contributor

@chrisdenman chrisdenman commented Sep 27, 2024

Hi,

This PR contains:

  • Quite a few HTML fixes to make the files more standards compliant
  • Setting the height of an image to reflect the actual size (this will help with faster page layouts (no flashes)) another for an image width declaration that was off by 1.
  • Making links https instead of https
  • Adding a .gitignore file
  • A few JavaScript fixes to use e.g. const/let instead of var and, using === instead of == where appicable
  • A couple of spelling issues

As part of this work and, to ensure that I've not regressed anything, I created a new project (test.learnyouahaskell.github.io) which is dedicated to functionally testing your site. This projects contains some standard stuff (checking links work, checking link text, ... ). Also, it goes through the site taking screenshots using both firefox and chrom (on Linux) at two different browser widths (860 & 1024 currently). Then, I use ImageMagick to compare the screenshots from the PR branch with that from the live site.

I ensure that the screenshot directories contain identicall named files. After that, if the ImageMagick image signature for a screenshots indicates that there is a difference, I create a flicker image (animated gif) to easily check the visual differences.

Please find these flicker diagrams attached. There's nothing major. They show the two spelling instances, the image height correction and a similar image width correction.

I have not checked in the functional testing project yet... I want to tidy it up a bit more before I do, it's a little invovled and has no documentation presently. I hope to complete that this weekend. As part of getting the project onto GH I shall ensure that we have a complete set of screenshots of the current production site that we can use as a base going forwards.

I hope you find this useful. I think it will be useful going forwards for generating the site from markdown should that be an aim people find useful.

Thanks! Any comments/suggestions will be gladly received.

flickers_chrome_860_chapter-a-fistful-of-monads_0
flickers_chrome_860_chapter-functionally-solving-problems_6
flickers_chrome_860_chapters_4
flickers_chrome_860_faq
flickers_chrome_1024_chapter-a-fistful-of-monads_0
flickers_chrome_1024_chapter-functionally-solving-problems_6
flickers_chrome_1024_chapters_4
flickers_chrome_1024_faq
flickers_firefox_860_chapter-a-fistful-of-monads_0
flickers_firefox_860_chapter-functionally-solving-problems_6
flickers_firefox_860_chapters_4
flickers_firefox_860_faq
flickers_firefox_1024_chapter-a-fistful-of-monads_0
flickers_firefox_1024_chapter-functionally-solving-problems_6
flickers_firefox_1024_chapters_4
flickers_firefox_1024_faq

…f the <html> tags.

I've presumed that the language is 'en-GB' as opposed to 'en-US' e.g. and this seems consistent with the text.
… to GitHub that should only exist locally.

I've added an entry for the IDE I use to work with projects.
…height is actually 168, I presume this was a copy/paste error.
Although this is a minor issue, it removes a warning in my IDE and makes the script less brittle against possible future changes.
The second 'nofollow' value is simply ignored by HTML parsers. Removing this link does not alter the page-ranking score for our site. It may alter the ranking of the linked licence (though I doubt it) and, I don't think that that should concern us.
…present at the bottom of each page.

'var' is no longer really acceptable and in our use-cases, 'const' is the way to go semantically. The values are not-reassigned. 'var' can lead to some unintended consequences.
…gle-analytics-host-to-pull-the-script-from' into all_prs

# Conflicts:
#	docs/a-fistful-of-monads.html
#	docs/chapters.html
#	docs/faq.html
#	docs/for-a-few-monads-more.html
#	docs/functionally-solving-problems.html
#	docs/functors-applicative-functors-and-monoids.html
#	docs/higher-order-functions.html
#	docs/input-and-output.html
#	docs/introduction.html
#	docs/making-our-own-types-and-typeclasses.html
#	docs/modules.html
#	docs/recursion.html
#	docs/starting-out.html
#	docs/syntax-in-functions.html
#	docs/types-and-typeclasses.html
#	docs/zippers.html
# Conflicts:
#	docs/chapters.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant