Coder Social home page Coder Social logo

Comments (2)

mikesmithgh avatar mikesmithgh commented on May 24, 2024 1

Hey @tummetott, thanks! I agree the configuration for kitty-scrollback.nvim can be improved. I added the details of his ticket to #69 where I plan on redesigning kitty-scrollback.nvim's configuration.

Have you seen any issues with kitty-scrollback.nvim after this change to your config? If you have any other ideas on how the configuration can be improved, feel free to share 👍

from kitty-scrollback.nvim.

tummetott avatar tummetott commented on May 24, 2024 1

Have you seen any issues with kitty-scrollback.nvim after this change to your config?

Initially, I tried symlinking just the kitty_scrollback_nvim.py file, but I encountered Python errors due to this script loading other Python files in the same directory. As a result, I opted to symlink the entire plugin directory, which has been working seamlessly without any issues so far.

If you have any other ideas on how the configuration can be improved, feel free to share 👍

I have an additional suggestion to further simplify the configuration process. It would be highly beneficial if configuration entries could accept both functions and tables. For instance, consider the following:

require('kitty-scrollback').setup {
    global = function()
        return {
            paste_window = { ... },
            kitty_get_text = { ... },
        }
    end,
}

can also be configured as

require('kitty-scrollback').setup {
    global = {
        paste_window = { ... },
        kitty_get_text = { ... },
    },
}

or

winopts_overrides = function()
    return {
        border = 'rounded',
        row = ...
        col = ...
    }
end

could also be configured as:

winopts_overrides = {
    border = 'rounded',
    row = ...
    col = ...
}

There are scenarios where using a function is the most appropriate choice, especially when specific configuration values need to be computed dynamically at runtime. However, there are equally valid situations where the table returned by the function consists of static values that do not require any dynamic computation. In such cases, the function wrapper may appear to introduce unnecessary boilerplate code, potentially complicating the configuration unnecessarily. Thus, offering the option to directly provide a table can greatly simplify the configuration process for these static values, making it more intuitive and concise.

from kitty-scrollback.nvim.

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.