Swiftpack.co -  johnfairh/SourceMapper as Swift Package
Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
johnfairh/SourceMapper
Create and edit Source Maps in Swift
.package(url: "https://github.com/johnfairh/SourceMapper.git", from: "1.0.0")

Platforms codecov Tests

SourceMapper

Simple Swift implementation of the SourceMap specification: create, load, query, modify, and save source maps.

Examples

let map = try SourceMap(data: try Data(contentsOf: mapURL))
let segment = map.map(line: 12, column: 0)
let map = SourceMap()
map.sources = [.remote("a.scss")]
map.sourceRoot = "./../src/"
map.setSegments(...)
let mapData = try map.encode()

Documentation

No support for:

  • Extension fields
  • Index map format

Requirements

  • Swift 5.3
  • macOS 10.10 (tested on macOS 11.0 IA64)
  • Linux (tested on Ubuntu 18.04.5)
  • Windows 10, Swift 5.4 (tested in CI only)

Installation

Only with Swift Package Manager, via Xcode or directly:

Package dependency:

.package(name: "SourceMapper",
         url: "https://github.com/johnfairh/SourceMapper.git",
         from: "1.0.0")

Contributions

Welcome: open an issue / johnfairh@gmail.com / @johnfairh

License

Distributed under the MIT license.

GitHub

link
Stars: 1
Last commit: 1 week ago

Ad: Job Offers

iOS Software Engineer @ Perry Street Software
Perry Street Software is Jack’d and SCRUFF. We are two of the world’s largest gay, bi, trans and queer social dating apps on iOS and Android. Our brands reach more than 20 million members worldwide so members can connect, meet and express themselves on a platform that prioritizes privacy and security. We invest heavily into SwiftUI and using Swift Packages to modularize the codebase.

Release Notes

1.0.0
8 weeks ago

First release

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API