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

Update grab.py such that code snippets is visible in the website. #95

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Abinash-bit
Copy link

Preserving Code Snippets:

In the strip_tags() function, the <pre> and <code> tags are replaced with appropriate .. code-block:: and inline code formatting for reStructuredText (rst).

Handling Code in HTML Content:

In html2rst_allign_post() , any HTML <pre> and <code> blocks are converted to rst code blocks, ensuring that code snippets are properly formatted on the OA website.

Feed Parsing

The grab_student() function correctly fetches content from RSS feeds and processes either the full HTML content or summary based on the availability.

Before

Screenshot 2024-10-09 093100

After

Screenshot 2024-10-09 093036

So this fixes #53 .

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.

When pulled from Medium, the articles do not show the code snippets embedded in them.
1 participant