Search code examples
xcodeswift-playground

Showing image in Swift Playground Markup


I'd like to show image in my markup document in swift playground file. Here is the code:

//: ![Alt text](1.png) 
//: ![Xcode icon](http://devimages.apple.com.edgekey.net/assets/elements/icons/128x128/xcode.png "Some hover text")

1.png is in the same directory as my playground file. But both are not working.

enter image description here

Any idea? Thanks.


Solution

  • Make sure that your image in the Playground Resource folder and then select the Show Rendered Markup from the Xcode editing menu.