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

fix blog images and re-add all blogs #497

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

fix blog images and re-add all blogs #497

wants to merge 9 commits into from

Conversation

ariyin
Copy link
Contributor

@ariyin ariyin commented Jan 23, 2025

Changes

  • Added rehype-raw package to translate HTML in Markdown correctly
  • Fixed image paths for blogs and limited images to max width of 100%
  • Replaced tables with screenshots of the tables since React Markdown can't convert it
  • Added all the blogs to the site
  • Deleted some unused images

me when i change 32 files in one pr:

image

Type of change

  • Content Update (non-breaking change which updates the content of the website)

Other notes

i hope i wrote and converted everything correctly... please help me double-check 🥺. i decided to leave the broken image in "Hackschool: Javascript and the DOM" since i couldn't decide what to do with it and removing it probably would've left readers more confused. estimated reading times were calculated with this website: https://niram.org/read/.

Related Issues

#468 #469

ong this is NOT a "good first issue" this got me lowk dead 😭

Copy link
Contributor

@nathanzzhang nathanzzhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

overall lgtm, just a few questions about formatting the blog posts!

}

function product(a, b, c) {
return a * b * c;
return a * b * c;
}

const args = [1, 2];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

curious as to how this shows up on the blog. if the comments are no longer aligned (as it was before), can we change this back so the comments are aligned for readability?

<button onClick={this.incrementCounter}> plus 1 </button>
</div>
);
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm if the spacing reflected here shows exactly on the blog page, maybe we want to reconsider using tabs and revert back to the previous spacing for readability. lowk this would apply to all code snippets in all blogs...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ngl idk if i can manually do it for all the files..

And yes, `bind`, `call`, `apply` do not work on arrow functions.
In fact, the arrow function can be equivalently written as

```js
const a = () => {};
// is equivalent to
const a = (function () {}).bind(this);
const a = function () {}.bind(this);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe add back parentheses for clarity?

<li>{s}</li>
))}
</ul>
);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

revert this change in formatting. less readable than the previous

))}
</ul>
</div>
);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same idea here, I would revert formatting

))}
</ul>
</div>
);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same idea on formatting

))}
</ul>
</div>
);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same idea on formatting

};
const handleUserNameChange = e => {
setUsername(e.target.value);
};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think we should still use the parentheses here for clarity (applies to all examples in this blog)

@ariyin
Copy link
Contributor Author

ariyin commented Jan 23, 2025

@jamesmwu something's going on w the linter and it's changing the formatting for all the files (most notably fucking up the tabbing in the code snippets). i tried reverting the commit and re-committing without the linter but that didn't help at all. any ideas?

@jamesmwu
Copy link
Contributor

@jamesmwu something's going on w the linter and it's changing the formatting for all the files (most notably fucking up the tabbing in the code snippets). i tried reverting the commit and re-committing without the linter but that didn't help at all. any ideas?

Hmm I'm not particularly sure what's going on here, but you might need to manually adjust the linting rules in eslint. Or it could be if you have Prettier maybe you have a Prettier config that's overriding the styles we expect? If you aren't able to figure it out we can take a look at it during meeting this Sat 👍

@ariyin
Copy link
Contributor Author

ariyin commented Jan 23, 2025

@jamesmwu something's going on w the linter and it's changing the formatting for all the files (most notably fucking up the tabbing in the code snippets). i tried reverting the commit and re-committing without the linter but that didn't help at all. any ideas?

Hmm I'm not particularly sure what's going on here, but you might need to manually adjust the linting rules in eslint. Or it could be if you have Prettier maybe you have a Prettier config that's overriding the styles we expect? If you aren't able to figure it out we can take a look at it during meeting this Sat 👍

i don't think it's prettier cuz the spaces in the files are normal. it's just that when it gets pushed onto github it becomes rlly weird. i tried it w/o the lint and it still pushed weird so i'm not rlly sure what's going on.

Copy link

netlify bot commented Feb 25, 2025

Deploy Preview for acm-hack ready!

Name Link
🔨 Latest commit 7f9f76f
🔍 Latest deploy log https://app.netlify.com/sites/acm-hack/deploys/67bd350cdf21f90008121410
😎 Deploy Preview https://deploy-preview-497--acm-hack.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

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.

3 participants