How to Remove Variable Border? - sublimetext2

I do not want to appear in this border when writing.
my theme is soda.
installed package: sublimelint and sublimerepl.
Language: Python
Problem Solved. I deleted the sublimelint package

Related

How to use Font Awesome 5 with Svelte/Sappe

I am writing a Server Side Rendered app with Svelte/Sapper and I am having trouble using Font Awesome fonts.
I am using the following to load the font:
<script>
import Icon from "svelte-awesome";
import { faTimes } from "#fortawesome/free-solid-svg-icons/faTimes";
</script>
<Icon data={faTimes} />
The error I am seeing is:
" is not a valid SSR component. You may need to review your build config to ensure that dependencies are compiled, rather than imported as pre-compiled modules"
Is there a solution to this?
I landed on this page looking for ways to import just the FontAwesome CSS into Svelte without any additional components or dependencies. Turns out that with Svelte this is just as simple as with plain HTML: Get the FontAwesome CSS (e.g. via package manager, CDN, or download) and add it to the HTML <head> section.
I like to install it via npm to maintain its version together with all other depencies:
npm install --save #fortawesome/fontawesome-free
After installing, just add the stylesheet (from the #fortawesome directory inside node_modules) to the <head> section of app.html.
<head>
...
<link href="./../node_modules/#fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet">
...
</head>
Use FontAwesome icons in your Svelte components, e.g. <i class="fa-regular fa-lightbulb">
For svelete-aweome, the import should look as follows in Sapper:
import Icon from 'svelte-awesome/components/Icon';

React path to public folder in css background image

I am using Create-React-App and I want to add background image for my header section and I am doing this in that way:
background-image: url('~/Screenshot_11.png');
After this I'm getting this error:
./src/styles/main.scss
(./node_modules/css-loader/dist/cjs.js??ref--6-oneOf-5-1!./node_modules/postcss-loader/src??postcss!./node_modules/sass-loader/lib/loader.js??ref--6-oneOf-5-3!./src/styles/main.scss)
Module not found: You attempted to import
../../../../../../../Screenshot_11.png which falls outside of the
project src/ directory. Relative imports outside of src/ are not
supported.
I've set up homepage in package.json
"homepage": "http://localhost:3000",
In my older projects that works but today I cannot import this correctly.
They have changed that but I don't know why. Working path:
background-image: url('/Screenshot_11.png');
EDIT 2021
For people who think that it doesn't work:
https://codesandbox.io/s/agitated-turing-gsnr3
you can import that image as
import Background from './Screenshot_11.png'
and use
background-image: `url(${Background})`
This still does not work for me with images in the public folder.
UPDATED 19 March 2021
Regarding using of <ROOT/public/images> in .css files.
It appears to be a breaking change (will be considered as a bug?) in create-react-app (react-scripts) package v4.x.
And more precisely in package 'css-loader' v4.x.
3.x branch works OK with that.
Here is the corresponding issue on the github repo:
https://github.com/facebook/create-react-app/issues/9870
(and there are few more actually).
No fixes (yet). (will be?..)
But a few workarounds mentioned there.
Which one to use... it depends on your project, I suppose.
Some of workarounds:
downgrade to react-scripts 3.4.x
don't use url in CSS files :) you still can use in .JSX (inline styles). Or put in .html. They are obviously not processed by css-loader.
reconfigure webpack to add url:false to css-loader options (either eject CRA or use this: https://github.com/gsoft-inc/craco or this: https://github.com/timarney/react-app-rewired
(you can find sample configurations at the github issue page)
use this new feature of css-loader https://github.com/webpack-contrib/css-loader/pull/1264
(released in 5.1.0, current last version is 5.1.3; to use that version you can add the following to the package.json: "resolutions": { "css-loader": "5.1.3" } (at root level) )

Jupyter Notebook cell output cut off/truncated by margin caused by Jupyter Themes

My cell output in Jupyter Notebook is cut off on the left hand side which obscures the leftmost output. For reference (I can't post images yet):
https://imgur.com/gallery/rg759nN
Any idea how to fix this?
EDIT: Thanks to rabbit on below, the problem seems to be caused by using the alternate themes provided by Jupyter Themes
Found the solution on Jupyter Themes github page:
https://github.com/dunovank/jupyter-themes/issues/288
"In the custom.css file, I fixed it by changing both the div.out_prompt_overlay.prompt's and the div.out_prompt_overlay.prompt:hover's min-width and width values to 11.5ex instead of the original 14.5ex."
Alternatively I added the padding:
div.output_area {
display: -webkit-box;
padding: 13px;
}
To the chesterish.css file (which was the theme I was using) and reapplied the theme using jupyter themes.
Ctrl + Shift + C to open DevTools in the browser.
go to Sources and click on static
search for: div.output_area
change padding to 13px
(The developer missed 1 and put only 3px distance)
This was raised as a bug and fixed (see https://github.com/dunovank/jupyter-themes/issues/273). As stated by Ernest in a comment: the solution is to upgrade the package and load the theme again i.e.
pip install --upgrade jupyterthemes
jt -t {theme}
you need to fix the container-margins in the command line by:
jt -m 100
and then:
jupyter notebook
(100 was good for me)

Run polymer in visual studio 2015

Hi I want to execute polymer component(polymer3.x) in visual studio,I am able to run polymer cli and polymer serve and I can see outputs.but when I try to execute my code in visual studio project I get `error
Failed to resolve module specifier
"#polymer/polymer/lib/utils/import-href.js". Relative references must
start with either "/", "./", or "../".
I find this link https://github.com/Polymer/tools/issues/363 but I am confused what should I change ?
By the way I change my relative path #polymer/polymer/ to ../polymer/polymer/ but not work
`
I tried with visual studio 2017 and it work but relative paths are important
in polymer element polymer-element.js must be imported
import { PolymerElement, html } from
'../node_modules/#polymer/polymer/polymer-element.js';
and in your html page webcomponents-loader.js must be added,and you add your polymer eleement with script which type is module
> <script
> src="node_modules/#webcomponents/webcomponentsjs/webcomponents-loader.js"></script>
>
> <script src="component/my-polymerelement.js" type="module">

Comment snippets package of sublime text is not working in css

I installed sublime text and included comment snippets (https://packagecontrol.io/packages/Comment-Snippets) it's working in html and others languages but it doesn't work in css whenever i wrote my comments like this:
comm-section
it gives me this output:
comm-section: ;
in html
/*=============================================
= Section comment block =
=============================================*/
/*----- End of Section comment block ------*/
how to be fixed in css like in html
Thanks for replying
I've had this problem before, the main reason why this isn't working is because you have "EMMET" package installed and it's overriding it.
If you find yourself not really using EMMET's shortcut for css, you can disable it in EMMET's settings.
Go into Sublime: SublimeText -> Preferences -> Package Settings -> Emmet -> Settings User
Open it and type in:
{
"disable_tab_abbreviations_for_scopes": "source.css"
}
Save it, then try your comments again. It should work now.