question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support an external config file instead of just package.json config

See original GitHub issue

Issuehunt badges

This is somewhat of a similar ask to #250, but with a little different use context:

I’d like to put my XO configuration in a separate file (.xorc.*), just like how ESLint and Prettier do it.

Having all of those config options in a single file really clutters up my package.json, and I’d like to be able to more easily copy/symlink files from a central location, instead of having to copy/paste configurations into my package.json every time.


IssueHunt Summary

pvdlg pvdlg has been rewarded.

Backers (Total: $80.00)

Submitted pull Requests


Tips


IssueHunt has been backed by the following sponsors. Become a sponsor

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:6
  • Comments:10 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
pvdlgcommented, Jun 6, 2018

A reason to adopt cosmiconfig would be https://github.com/xojs/xo/pull/279#issuecomment-356021126

1reaction
sindresorhuscommented, Jun 6, 2018

and I’d like to be able to more easily copy/symlink files from a central location, instead of having to copy/paste configurations into my package.json every time.

Why are you copy-pasting the config each time? That sounds like a maintenance nightmare. Instead, just create a shareable ESLint config file and all you need in your package.json is:

{
	"xo": {
		"extends": "name-of-your-shareable-config"
	}
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Should I put every kind of configuration in package.json file ...
One way is to store their configuration in package. json . Another way is store this configuration in their special config file, like...
Read more >
package.json
This document is all you need to know about what's required in your package.json file. It must be actual JSON, not just a...
Read more >
How to store Node.js deployment settings/configuration files?
I use a package.json for my packages and a config.js for my configuration, which looks like: var config = {}; config.twitter = {};...
Read more >
Configuration Files - ESLint - Pluggable JavaScript Linter
A pluggable and configurable linter tool for identifying and reporting on patterns in JavaScript. Maintain your code quality with ease.
Read more >
jsconfig.json Reference - Visual Studio Code
The presence of jsconfig.json file in a directory indicates that the ... Below are jsconfig "compilerOptions" to configure the JavaScript language support.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found