Code Monkey home page Code Monkey logo

Comments (9)

jtdaugherty avatar jtdaugherty commented on July 30, 2024

I have thought about doing this very thing. I even want to have the lens-style API confined to a separate brick-lens package. But even if I switched to another lens implementation, it wouldn't save any time because vty uses lens. I have approached Corey about removing the lens dependency from vty so I can achieve the same with my library. Please pile on at jtdaugherty/vty#90

from brick.

jtdaugherty avatar jtdaugherty commented on July 30, 2024

On second thought, putting all the lens support in a separate package would be annoying to me because I'd always want it, so let's leave the lens API in the main package. However, I would be happy to port to microlens (provided its API is big enough). I am not sure when I'll have time to get to it, but I would be happy to consider patches to this effect. :)

from brick.

jtdaugherty avatar jtdaugherty commented on July 30, 2024

A big part of this port would also be to carefully look over the User Guide to ensure that it mirrors the lens API.

from brick.

neongreen avatar neongreen commented on July 30, 2024

microlens does mirror the lens API, yep. I just noticed that I didn't have a migration guide for microlens, so I wrote one.

I looked at your code and I think it's possible for you to migrate. The only complication is going to be this – you define your own instances of Field1 and Field2, but lens's Field1 does not equal microlens's Field1 and so users who import Control.Lens won't be able to use _1/_2 with Location. If you don't intend your users to use them anyway, it's okay – but otherwise you might have to rename them to e.g. rowL/columnL.

from brick.

jtdaugherty avatar jtdaugherty commented on July 30, 2024

The ticket jtdaugherty/vty#90 is now closed, so when I get time I'll migrate brick to microlens (and cut a new release of vty).

from brick.

jtdaugherty avatar jtdaugherty commented on July 30, 2024

This is now done and released:

http://hackage.haskell.org/package/vty-5.5.0
http://hackage.haskell.org/package/brick-0.6

from brick.

simonmichael avatar simonmichael commented on July 30, 2024

And now hledger-ui installs quicker (at least 9 fewer deps). Thank you!

from brick.

jtdaugherty avatar jtdaugherty commented on July 30, 2024

Fantastic!

from brick.

jtdaugherty avatar jtdaugherty commented on July 30, 2024

@neongreen - thanks for writing that guide!

from brick.

Related Issues (20)

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.