Skip to content
This repository has been archived by the owner on Jan 24, 2025. It is now read-only.

Feat/opt out format files #871

Closed

Conversation

patricksevat
Copy link
Contributor

Description

This PR addresses two issues:

  1. Fixing developing on Windows (again) known under and prev fixed by Docz not building on Windows #783 fix(docz-rollup): fixed rollup configs to be Windows tolerant #783 #812 Docz external resolve fix #821 Docz external resolve fix #830 CC: @ejuo
  2. Adding a configuration option to opt out of Prettier formatting.
    This is useful for repo's that already do their own formatting (such as ours) and adds a feature to satisfy New option: prevent HTML transformation into self-closing tags #813 and [Feature? Bug?] Markdown without line wrapping #865 CC: @sw-yx

Review

  • Check the copy
  • ...
  • ...

Pre-merge checklist

  • ...
  • ...

Screenshots

Before After
Image
image image

@patricksevat patricksevat changed the base branch from master to dev May 13, 2019 20:52
@pedronauck pedronauck changed the base branch from dev to feat/gatsby July 11, 2019 11:55
@rakannimer rakannimer changed the base branch from feat/gatsby to dev September 4, 2019 06:47
@rakannimer
Copy link
Contributor

Hey @patricksevat

Sorry for the late reply and thank you for taking the time to create this PR.

Could you rebase your branch with dev to fix the conflicts ? Or if you prefer, open a new PR with a branch starting from dev and with your changes only.

Would love to merge but it has conflicts.

@patricksevat
Copy link
Contributor Author

Hi @rakannimer ,

No worries about the delay, I'm just glad that Docz is alive and kicking again thanks to you and Pedro. Really like the work you guys are doing.

Bit busy now, but I'll try to rebase in the weekend

@rakannimer rakannimer force-pushed the dev branch 3 times, most recently from 03b85ba to 5635050 Compare September 6, 2019 06:03
@patricksevat
Copy link
Contributor Author

patricksevat commented Sep 8, 2019

Hi @rakannimer

I just checked worked a bit on this, but from what I can see it appears that Prettier is no longer applied to user provided .mdx files, which is great in my opinion.

In my research I did find some things I wanted to share, and it's up to you if you want to fix it:

  1. Adding a code block with three backticks does not work without providing a language:
    ```
    // Does not work
    Hello world
    ```
    ```md
    // Does work
    Hello world
    ```

  2. gatsby-theme-docz/src/components/Code/index.js adds a .trim() on children which I'm not completely sure why. For example in Markdown code blocks you might want to space something, but this prevents it

  3. docz-utils/src/format.ts looks like it is barely used anymore (only to template some gatsby related files) and docz-utils/src/fs.ts looks like it is not used at all anymore. Maybe you can verify and remove for less maintenance and dependencies

  4. In order to develop Docz on Windows one of the PRs from this issue needs to be reapplied again: Docz not building on Windows #783

@patricksevat patricksevat deleted the feat/opt-out-format-files branch September 8, 2019 00:15
@rakannimer
Copy link
Contributor

Thanks a lot @patricksevat for the report (especially the Windows issue).

I'll add the tasks you indicated as todos and get on them ASAP.

Cheers

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants