Giter VIP home page Giter VIP logo

down's People

Contributors

128keaton avatar 5sw avatar aasimk2000 avatar claurel avatar e-kazakov avatar foxware00 avatar invlid avatar iwasrobbed avatar johnxnguyen avatar kengruven avatar kumuluzz avatar larryonoff avatar mathebox avatar max-potapov avatar mdiep avatar mfcollins3 avatar mgacy avatar michaelknoch avatar mjzac avatar nheagy avatar njdehoog avatar phoney avatar pieromattos avatar sgoodwin avatar stevebaranski avatar tonyarnold avatar vgorloff avatar vzsg avatar xquezme avatar ykphuah avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

down's Issues

Image caching

  • I've searched other open/closed issues for duplicates before opening up this new issue.

I have to cache the images in the markdown for offline usage. Is there any way to achieve this?

How to customize the Font?

I create an attributedString with your lib. How can I change the font-size?

An example in your doc would be very helpful.

Some warnings to fix

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

Just installed via CocoaPods.

What did you expect to happen?

No warnings or errors.

What happened instead?

  1. Don't know how but there are 4 non-compilable sources in the Compile Sources list. I forked the Down project and see that there are not in the Compile Sources list. Odd.

    • case_fold_switch.inc
    • COPYING
    • entities.inc
    • module.modulemap
  2. latex.c line 185: realurllen = url_len; gives warning:
    Implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'int'

    A type casting solves the issue.
    realurllen = (int) url_len;

P.S: Thank you for this great spec! It saved a life!

A faster substitute to NSHTMLTextDocumentType?

Hi!

Can be Down a better and faster substitute to render html inside a textview?
For example, is possible to use Down to improve the rendering of complex html inside a table view cell?
Actually i'm using an attributed string with this option [NSDocumentTypeDocumentAttribute: NSHTMLTextDocumentType] but the rendering is too slow.

Thanks
-Paolo

Xcode 8.3 warnings

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

It's just me or everyone also have 5 warnings in the new Xcode 8.3? All of them apparently are in the cmark code btw.

screen shot 2017-04-05 at 14 39 00

The first 4 apparently can be fixed by removing this 4 files from the build phase, the other one is a type problem

Compilation error using Carthage

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

The framework installation through Carthage failed

What did you do?

  • Create a new iOS project (Xcode 9)
  • Create the Carthfile
  • Run carthage update

What did you expect to happen?

Install and being able to use the framework

What happened instead?

Failed!

This is the command output:

❯ carthage update                                                                                           ✭
*** Fetching Down
*** Checking out Down at "v0.4.2"
*** xcodebuild output can be found in /var/folders/kg/qvgj2__s63d29ykthhcm5wd0000276/T/carthage-xcodebuild.as0dwq.log
*** Building scheme "Down" in Down.xcodeproj
Build Failed
	Task failed with exit code 65:
	/usr/bin/xcrun xcodebuild -project /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Down.xcodeproj -scheme Down -configuration Release -derivedDataPath /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2 -sdk watchos ONLY_ACTIVE_ARCH=NO BITCODE_GENERATION_MODE=bitcode CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY= CARTHAGE=YES archive -archivePath ./ SKIP_INSTALL=YES GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=NO CLANG_ENABLE_CODE_COVERAGE=NO (launched in /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down)

This usually indicates that project itself failed to compile. Please check the xcodebuild log for more details: /var/folders/kg/qvgj2__s63d29ykthhcm5wd0000276/T/carthage-xcodebuild.as0dwq.log

And this is the log:

/usr/bin/xcrun xcodebuild -project /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Down.xcodeproj -scheme Down -configuration Release -derivedDataPath /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2 -sdk watchos ONLY_ACTIVE_ARCH=NO BITCODE_GENERATION_MODE=bitcode CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY= CARTHAGE=YES archive -archivePath ./ SKIP_INSTALL=YES GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=NO CLANG_ENABLE_CODE_COVERAGE=NO (launched in /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down)User defaults from command line:
    IDEArchivePathOverride = /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down
    IDEDerivedDataPathOverride = /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2

Build settings from command line:
    BITCODE_GENERATION_MODE = bitcode
    CARTHAGE = YES
    CLANG_ENABLE_CODE_COVERAGE = NO
    CODE_SIGN_IDENTITY =
    CODE_SIGNING_REQUIRED = NO
    GCC_INSTRUMENT_PROGRAM_FLOW_ARCS = NO
    ONLY_ACTIVE_ARCH = NO
    SDKROOT = watchos4.0
    SKIP_INSTALL = YES

=== BUILD TARGET Down OF PROJECT Down WITH CONFIGURATION Release ===

Check dependencies

Write auxiliary files
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-all-non-framework-target-headers.hmap
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-project-headers.hmap
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/module.modulemap
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/all-product-headers.yaml
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-generated-files.hmap
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-all-target-headers.hmap
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down.hmap
/bin/mkdir -p /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down-OutputFileMap.json
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down.LinkFileList
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-own-target-headers.hmap
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/swift-overrides.hmap
/bin/mkdir -p /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/DerivedSources
write-file /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/DerivedSources/Down_vers.c

Create product structure
/bin/mkdir -p /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/UninstalledProducts/watchos/Down.framework/Modules
/bin/mkdir -p /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/UninstalledProducts/watchos/Down.framework/Headers

ProcessInfoPlistFile /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/UninstalledProducts/watchos/Down.framework/Info.plist Resources/Down-Info.plist
    cd /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down
    export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/username/.rvm/gems/ruby-2.3.0/bin:/Users/username/.rvm/gems/ruby-2.3.0@global/bin:/Users/username/.rvm/rubies/ruby-2.3.0/bin:/usr/local/opt/libxml2/bin:/Users/username/.swiftenv/shims:/Users/username/.nvm/versions/node/v8.7.0/bin:/opt/local/bin:/opt/local/sbin:/Users/username/.cargo/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/Users/username/.rvm/bin"
    builtin-infoPlistUtility /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Resources/Down-Info.plist -expandbuildsettings -format binary -platform watchos -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/UninstalledProducts/watchos/Down.framework/Info.plist

SymLink /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos/Down.framework /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/UninstalledProducts/watchos/Down.framework
    cd /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down
    export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/username/.rvm/gems/ruby-2.3.0/bin:/Users/username/.rvm/gems/ruby-2.3.0@global/bin:/Users/username/.rvm/rubies/ruby-2.3.0/bin:/usr/local/opt/libxml2/bin:/Users/username/.swiftenv/shims:/Users/username/.nvm/versions/node/v8.7.0/bin:/opt/local/bin:/opt/local/sbin:/Users/username/.cargo/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/Users/username/.rvm/bin"
    /bin/ln -sfh /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/UninstalledProducts/watchos/Down.framework /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos/Down.framework

CompileSwiftSources normal armv7k com.apple.xcode.tools.swift.compiler
    cd /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down
    export DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer
    export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Users/username/.rvm/gems/ruby-2.3.0/bin:/Users/username/.rvm/gems/ruby-2.3.0@global/bin:/Users/username/.rvm/rubies/ruby-2.3.0/bin:/usr/local/opt/libxml2/bin:/Users/username/.swiftenv/shims:/Users/username/.nvm/versions/node/v8.7.0/bin:/opt/local/bin:/opt/local/sbin:/Users/username/.cargo/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/Users/username/.rvm/bin"
    export SDKROOT=/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS4.0.sdk
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swiftc -incremental -module-name Down -O -whole-module-optimization -Xfrontend -disable-swift3-objc-inference -sdk /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS4.0.sdk -target armv7k-apple-watchos3.0 -g -module-cache-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/ModuleCache -Xfrontend -serialize-debugging-options -embed-bitcode -swift-version 4 -I /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos -I /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/cmark -F /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos -c -num-threads 8 /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Extensions/NSAttributedString+HTML.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Views/DownView.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownAttributedStringRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownHTMLRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Extensions/String+ToHTML.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownXMLRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Enums\ &\ Options/DownOptions.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownGroffRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownCommonMarkRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Down.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownLaTeXRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Enums\ &\ Options/DownErrors.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownASTRenderable.swift -output-file-map /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down-OutputFileMap.json -parseable-output -serialize-diagnostics -emit-dependencies -emit-module -emit-module-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down.swiftmodule -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/swift-overrides.hmap -Xcc -iquote -Xcc /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-generated-files.hmap -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-own-target-headers.hmap -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-all-non-framework-target-headers.hmap -Xcc -ivfsoverlay -Xcc /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/all-product-headers.yaml -Xcc -iquote -Xcc /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-project-headers.hmap -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos/include -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/DerivedSources/armv7k -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/DerivedSources -emit-objc-header -emit-objc-header-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down-Swift.h -Xcc -working-directory/Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down

CompileSwift normal armv7k
    cd /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift -frontend -emit-bc /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Extensions/NSAttributedString+HTML.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Views/DownView.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownAttributedStringRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownHTMLRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Extensions/String+ToHTML.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownXMLRenderable.swift "/Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Enums & Options/DownOptions.swift" /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownGroffRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownCommonMarkRenderable.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Down.swift /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownLaTeXRenderable.swift "/Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Enums & Options/DownErrors.swift" /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Renderers/DownASTRenderable.swift -target armv7k-apple-watchos3.0 -enable-objc-interop -sdk /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS4.0.sdk -I /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos -I /Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/cmark -F /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos -g -module-cache-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/ModuleCache -swift-version 4 -disable-swift3-objc-inference -serialize-debugging-options -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/swift-overrides.hmap -Xcc -iquote -Xcc /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-generated-files.hmap -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-own-target-headers.hmap -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-all-non-framework-target-headers.hmap -Xcc -ivfsoverlay -Xcc /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/all-product-headers.yaml -Xcc -iquote -Xcc /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Down-project-headers.hmap -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-watchos/include -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/DerivedSources/armv7k -Xcc -I/Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/DerivedSources -Xcc -working-directory/Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down -emit-module-doc-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down.swiftdoc -serialize-diagnostics-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/NSAttributedString+HTML.dia -O -module-name Down -emit-module-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down.swiftmodule -emit-objc-header-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down-Swift.h -emit-dependencies-path /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/NSAttributedString+HTML.d -num-threads 8 -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/NSAttributedString+HTML.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownView.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownAttributedStringRenderable.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownHTMLRenderable.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/String+ToHTML.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownRenderable.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownXMLRenderable.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownOptions.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownGroffRenderable.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownCommonMarkRenderable.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/Down.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownLaTeXRenderable.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownErrors.bc -o /Users/username/Library/Caches/org.carthage.CarthageKit/DerivedData/9.0.1_9A1004/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/IntermediateBuildFilesPath/Down.build/Release-watchos/Down.build/Objects-normal/armv7k/DownASTRenderable.bc
/Users/username/Development/personal/DownTesting/Carthage/Checkouts/Down/Source/Views/DownView.swift:12:8: error: no such module 'WebKit'
import WebKit
       ^

** ARCHIVE FAILED **


The following build commands failed:
	CompileSwift normal armv7k
	CompileSwiftSources normal armv7k com.apple.xcode.tools.swift.compiler
(2 failures)

iOS8 crash

env: XCode9/swift4
crashed on ios8/iphone6
dyld: Symbol not found: _NSCharacterEncodingDocumentOption

How to manually install (w/o Carthage or CocoaPods)

Download, open in Xcode, build, locate Down.framework folder, drag to target Xcode project.
However, "Use of unresolved identifier 'Down' " so I've missed a step somewhere.

Don't want to use carthage or pods, so how to install?
Thanks.

Markdown tables support

This is more of a question than an issue.
Does this library support markdown tables conversion to HTML? It doesn't work as far I checked.

Converting \n in paragraphs into <br>, while marking down an html

How can i convert \n in paragraphs into <br>?
In other words, is there any options that can make markdown newline (\n) between paragraphs to line break?

For example if the markdown looks like below:

Hi,<br>\n\ndadsaadsdsada<br>\n\n1\\. dsadsad\n2\\. ea2eqwewqewq\n3\\. dewacxzcxczxcxczc\n4\\. dasfdfdsfdfsdfsfs

How to show the output like


dadsaadsdsada

1. dsadsad
2. ea2eqwewqewq
3. dewacxzcxczxcxczc
4. dasfdfdsfdfsdfsfs```


Define custom fonts

Is there any way to define custom fonts to use for the output?
I'd need attributed strings where I can define which base-font to use, also which font for h1, h2, ...

Is that anyhow possible? I've seen you basically just give the input to cmark, but couldn't find any possibility to customize any font :(

Am I just missing something here?

`DocumentReadingOptionKey` Error via pod

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

ℹ Please replace this with what you did.

What did you expect to happen?

ℹ Please replace this with what you expected to happen.

What happened instead?

ℹ Please replace this with what happened instead (e.g. the issue).

While installing pod file getting error "DocumentReadingOptionKey is unavailable in Swift"

Add OS X support

Welcoming any pull requests to add OS X support for those who need it.

Swift 3+ convention for capitalization

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

When using Down, all of the non-type identifiers (funcs, vars, etc.) follow the Swift 3+ convention of starting with a lower-case letter, except in the case of struct DownOptions. It still uses the Swift 2 convention of UpperCase identifiers:

public static let SourcePos = DownOptions(rawValue: CMARK_OPT_SOURCEPOS)

What did you expect to happen?

I think Down should use the newer convention and call these symbols sourcePos, hardBreaks, etc.

What happened instead?

Down still uses the Swift 1/2 convention here: SourcePos, HardBreaks, etc.

This is a change to the public interface, but the project version number is still 0.x, so according to semver, breaking changes are allowed. Alternatively, it could define both capitalizations in the struct (like SourcePos and sourcePos), to allow users time to update their code.

Compiling error on example project

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

Clone the repo and run example project.

What did you expect to happen?

Running successfully.

What happened instead?

Compiling error "Missing required module 'libcmark'"

image

Syntax highlighting themes

This is a feature request.
Can you guys create any more themes.
It would be nice to Choose from a light or a dark theme for syntax highlighting

How to keep UITextView font style

Hi, as I use this module it overrides the font of the textView. Is there any way to set the font when initialising Down?

let down = Down(markdownString: markup) self.messageLabel.attributedText = try! down.toAttributedString()

[DownView] Load multiple .md files (link support)

  • I've searched other open/closed issues for duplicates before opening up this new issue.
    I've especially noticed #40 and here one issue with local images could successfully be solved.

Report

Help needed. For either DownView or a hint how to implement this.

Alternatively, the example could perhaps get a bit extended.

What did you do?

Loading a local .md file that has a link to another local .md file. E.g. you have

  ## In markdown file number one (one.md)
  [To markdown file number two](two.md)

What did you expect to happen?

Tapping on the link should load the other markdown file.

What happened instead?

Nothing. Also no exception or else in the console.

Carthage install fails: no such module 'libcmark'

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

Added Down to my Cartfile and ran carthage update --platform iOS. I'm using the latest version of Carthage (0.25.0). Xcode version 8.3.3

What did you expect to happen?

I expected the installation to complete successfully

What happened instead?

The carthage update failed when it got to Down:

Build Failed
    Task failed with exit code 65:

I checked the build logs, and noticed the error:

error: no such module 'libcmark'

Module file was created by an older version of the compiler

Seeing error:

MyProject/Pods/Down/Source/Views/DownView.swift:9:8: Module file was created by an older version of the compiler; rebuild 'WebKit' and try again: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos/arm64/WebKit.swiftmodule

macOS 10.11 support?

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

  • I built Down.framework for macOS, using Carthage.
  • Then I dragged the framework to my Mac application (which is built for 10.11).

What did you expect to happen?

The application would (still) build.

What happened instead?

Xcode refused to build the application, because Down.framework has MACOSX_DEPLOYMENT_TARGET = 10.12.

Down doesn't use any 10.12 APIs, though, so there doesn't appear to be any downside to changing it to MACOSX_DEPLOYMENT_TARGET = 10.11.

An older macOS target isn't out of line with the other supported platforms. Down.framework still claims to support iOS 8, for example, which is roughly the age of macOS 10.10.

Installing with Carthage for Mac fails

Please help prevent duplicate issues before submitting a new one:

  • [Y ] I've searched other open/closed issues for duplicates before opening up this new issue.

Report

I tried installing Down using Carthage 0.28.0. However, it errors out with the following

Failed to write to /Users/georgemp/TestProject/Carthage/Build/Mac/Down.framework: Error Domain=NSCocoaErrorDomain Code=260 "The file “Down.framework” couldn’t be opened because there is no such file." UserInfo={NSURL=file:///Users/georgemp/Library/Caches/org.carthage.CarthageKit/DerivedData/9.2_9C40b/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-iphoneos/Down.framework, NSFilePath=/Users/georgemp/Library/Caches/org.carthage.CarthageKit/DerivedData/9.2_9C40b/Down/v0.4.2/Build/Intermediates.noindex/ArchiveIntermediates/Down/BuildProductsPath/Release-iphoneos/Down.framework, NSUnderlyingError=0x7fd250923f10 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}}

What did you do?

Tried installing Down with the following commands

carthage update Down --platform Mac

carthage update Down --platform Mac --no-use-binaries

What did you expect to happen?

Expected to get a built Down.framework in Carthage/Build/Mac

What happened instead?

The build errored with the error message pasted in the report section

WatchKit Support

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

I'd like WatchKit support for Down.

What did you do?

I tried manually adding the Framework, however, this caused too many issues.

What did you expect to happen?

I didn't expect it to work, but I would like it to

What happened instead?

It didn't work

How to update DownView content and keep the style?

I can add a DownView to my view (use code below) but how can I update the content inside it?

    let cardFrontStr = "Use chained optional to simplify code below,\n\n```\nvar display: UILabel?\nif let label = display {\n  if let text = label.text {\n    let x = text.hasValue\n    // ...\n  }\n}\n```"
    let cardfrontView = try? DownView(frame: cardfront.bounds, markdownString: cardFrontStr)
    cardfront.addSubview(cardfrontView!)

Since the DownView is extended from WebView, I can update the content and loadHTMLString; however, the DownView style is gone after I have done so.

    let down = Down(markdownString: "`test`")
    let newStr = try? down.toHTML()
    cardbackView?.loadHTMLString(newStr!, baseURL: nil)

Objective-C support

This is one of the best frameworks for Markdown I've ever used. There aren't that many alternatives for Objective-C and I have to resort to HTML or WebViews.
Please add Objective-C support if it is possible.

Converting Markdown string to HTML with emojis

*[x] I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

I've inserted a markdown string with some emojis into it and used Down(markdownString: str).toHTML()

The markdown string was something like:

markdownString = """
		# Header 01
		## header 02
		
		**some bold text 0**
		*some italic text 0*
		
		> Blockquote text
		> multilined
		
               text with emojis: 👍😀🔞😈🤢🤖
		"""

What did you expect to happen?

Expected the toHTML() function parsed the emojis, so it would appear inside the WebView.

What happened instead?

The emojis unicode weren't parsed as expected, instead, for the emojis inserted (see above) the output inside the WebView after using the toHTML() function was the following:
(I'm reducing the unnecessary text)

text with emojis: �😀🔞😈🤢🤖

rendering markdown from file

I've tried to render a long markdown format string with Down, but it can't be recognised, the only way to do it is rendering one line by one line, like this

let inputArray = ["## Hello World", "- list1", "- list2"]
var output: String = ""
        
for input in inputArray {
    let down = Down(markdownString: input)
    // Convert to HTML
    let html = try? down.toHTML()
    output = "\(output)\(html!)"
}
        
self.webview.loadHTMLString(output, baseURL: nil)

wondering is there a better way to do it?

Installation via Swift Package Manager

Hi,

I wanted to try out this package (as it seems to be the only Swift package to provide access to a Markdown AST for custom transforms), but hadn't yet set up CocoaPods or Carthage on my sample CLI application.

I was wondering whether there was anything preventing this project to provide a Package.swift configuration to be installable via SPM and if not whether you have any objections to providing that option.

Thanks!

down.toAttributedString() custom text font and image size

due to different size of devices, can't just give a fixed size to image in markdown, is there a way to custom text font and image size after it been converted to NSAttributedString, or is there a markdown standard to make this happens?

  • markdown sample
this is a sample text and image
![](https://s3.atom2ueki.com/images/app_s_3.jpg)
  • code sample
...
let output:NSAttributedString = try! down.toAttributedString()
DispatchQueue.main.async {
    self.uitextview.attributedText = output
}
...

thanks!

NSAttributedString to Raw string

Is it possible to create a raw string from an NSAttributedString?
I'm thinking of something like

Down(attributedString: "bold, italic, regular").rawString // –> "**bold**, *italic*, regular"

Reason:
I want my users to be able to style a text (using the regular BIU) and then convert it to a raw string which I can store in the database to later convert that string back to a rendered NSAttributedString.

Thanks!

Example project

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

  1. I downloaded a zip with the project.
  2. I tried to run the project in Xcode.
  3. I realized that there was only unittests.

What did you expect to happen?

I'm usually looking for an Example project that shows how it looks on iOS or on macOS.

What happened instead?

There was no Example project, so I created this issue.

Unable to build with Xcode 9

Report

What did you do?

Building my OS X project with Down under Xcode 9 Beta 6 failed due to framework built with previous version of swift error. I then changed my local Down to be swift 4, updated the source, ran the few tests. Removed the existing Down framework and added the newly built one.

What did you expect to happen?

That my project would build.

What happened instead?

It still complains that the framework is built with an older version of Swift. I ensured the only copy is the one I built. Is there anything odd about the Down build settings?

Error building/installing Down

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

I downloaded the repo and ran xcodebuild to build the framework.

What did you expect to happen?

I expected to be able to run the function.

What happened instead?

I got this error message: 'DownView' is unavailable: cannot find Swift declaration for this class when I used the DownView() function.

Text Size of DownView too small

I added Down to my current project to display markdown on different views in different layouts.
For me it seems the text ist a little bit too small to be good readable.
I made some changes to the css file to display a bigger font size.

I am not sure if there is another way, like a config file, but that worked for me and could be an addition to the project.
Sn0wfreezeDev@c0d3f51

Push v0.4.1 to cocoapods

Please help prevent duplicate issues before submitting a new one:

  • I've searched other open/closed issues for duplicates before opening up this new issue.

Report

What did you do?

I tried to install 0.4.1 via cocoapods

What did you expect to happen?

I expected that cocoapods would be aware of 0.4.1

What happened instead?

No such version could be found, latest cocoapods version is 0.3.4. I was able to install by pointing to the v0.4.1 tag

It would be great to get the new version pushed to cocoapods so i can reference by version

Lists and paragraph spacing

Hi,

  1. I have set my paragraphSpacingAfter to 0 but I still have spacing between each li.
  2. Does the library support ordered lists at all?

This is my Custom styler for your reference:

struct BodyStyler: XMLStyler {
        
        func style(forElement name: String, attributes: [String: String], currentStyle: StringStyle) -> StringStyle? {
            let heading = StringStyle(
                .font(UIFont(brand: .regular, size: 18)),
                .color(.black),
                .lineSpacing(7),
                .adapt(.body)
            )
            
            let body = StringStyle(
                .font(UIFont(titillium: .regular, size: 17)),
                .color(.black),
                .adapt(.body)
            )
            
            switch name {
            case "h1", "h2", "h3":
                return heading
            case "b", "strong":
                return body.byAdding(
                    .font(UIFont(titillium: .bold, size: 17))
                )
            case "i", "em":
                return body.byAdding(
                    .font(UIFont(titillium: .italic, size: 17))
                )
            case "ul", "ol":
                let bulletStyle = body.byAdding(
                    .font(UIFont(titillium: .regular, size: 20)),
                    .color(.grayTint3),
                    .adapt(.body)
                )
                
                let bulletString = NSAttributedString.composed(of: ["", Tab.headIndent(4.0)], baseStyle: bulletStyle, separator: nil)
                
                return body.byAdding(
                    .xmlRules([
                        .style("li", StringStyle(
                            .paragraphSpacingAfter(0)
                        )),
                        .enter(element: "li", insert: bulletString),
                        .exit(element: "li", insert: "\n")
                    ])
                )
            case "a":
                guard let href = attributes["href"],
                    let url = URL(string: href) else {
                        return body
                }
                
                return body.byAdding(
                    .link(url),
                    .color(.warmRed),
                    .underline(.styleNone, .red)
                )
            default:
                return body
            }
        }
        
        func prefix(forElement name: String, attributes: [String: String]) -> Composable? {
            return nil
        }
        
        func suffix(forElement name: String) -> Composable? {
            return nil
        }
    }

build error

hello, i installed with pod, but when i build i got a error in XCode9/swift4/ios:
"""
DocumentReadingOptionKey' is unavailable in Swift
"'"
Could you tell me how can i fix this? 😶

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.