badlydrawnrob / anki

Learn to code with Anki — flashcards and themes for all learning levels. Master your programming language of choice!
MIT License
719 stars 61 forks source link

Visual Studio Code adds formatted text to Anki (when copying/pasting) #120

Closed badlydrawnrob closed 7 months ago

badlydrawnrob commented 7 months ago

⚠️ Copy and paste from Visual Studio Code ..... Adds formatted text to card text field

text-gets-styles-added-to-it

Solution

  1. Open the Command Palette (Ctrl+Shift+P)
  2. Type in "Preferences: Open User Settings (JSON)"
  3. Select this option and open your settings.json file
  4. Add "editor.copyWithSyntaxHighlighting": false" to the file

Alternative solution

Screenshot 2024-01-21 at 13 26 25
  1. In Anki desktop app, go to Preferences...[^1]
  2. Select Editing
  3. Select the Paste without shift key strips formatting checkbox

[^1]: My preference is to get rid of the formatted pasted text completely from Visual Studio Code. It seems like a ridiculous feature to have by default for a friggin' text editor!!!

badlydrawnrob commented 7 months ago

This is fixed now