►
From YouTube: Community demo - Library Components: NPM Link Quick Tip
Description
This community demo is taken from the SharePoint Summer camp community call on on 18th of July 2019. In this video, David Warner (Catapult Systems) shows quick tip on helping with the library component demonstration.
Presenter - David Warner (Catapult Systems) @DavidWarnerII
You can find more details around SharePoint Framework library components from following article - https://docs.microsoft.com/en-us/sharepoint/dev/spfx/library-component-overview
More details on the SharePoint dev community calls from http://aka.ms/sppnp.
A
Here's
my
contact
information
for
anybody
who
doesn't
already
know
me
feel
free
to
reach
out.
If
you
have
any
questions,
as
you
mentioned,
we're
gonna
talk
about
NPM,
install
gotcha
as
a
quick
tip
for
SharePoint
library,
components,
they're,
very,
very
cool
I'm,
not
gonna,
go
into
deep
on
the
library
components
themselves,
just
show
you
the
quick
tip
when
you
connect
a
web
part
to
a
library
component,
and
then
you
use
the
sim
link
and
then
you
later
install
an
NPM
module.
A
There's
a
little
gadget
that
you
need
to
be
aware
of
and
it'll
affect
your
node
modules
and
can
maybe
have
you
scratching
your
head
for
a
little
while
so,
hopefully
we're
gonna,
save
you
some
time
and
I'll
show
you
what's
gonna
happen
and
how
to
fix
it.
So
here's
the
context:
I've
created
a
library
component
I've
also
created
a
web
part
that
connects
to
the
library
component
and
it's
already
been
imported.
A
You
can
see
here,
I've
already
created
an
instance
of
my
library
component
here
and
I'm
console
logging,
just
the
version
method,
so
I'm
executing
the
version
method.
Now,
if,
if
you've
already
been
familiar
with
library
components,
you
know
that
you
need
to
utilize
the
NPM
link
command,
and
you
see
that
down
here
in
my
node
modules,
it's
already
connected
using
a
sim
link
to
my
J's
library
component,
but
let's
say
along
the
way:
I
need
to
go
in
and
I
need
to
install
some
other
node
modules.
A
So
we're
gonna
go
ahead
and
kick
that
off
and
do
NPM,
install
and,
of
course,
of
all
things.
We
always
want
to
go
ahead
and
install
PN
pjs
right.
So
I'm
gonna
start
that
install
now
keep
an
eye
down
here
on
the
node
modules
and
or
over
here
in
my
code,
you're
gonna
notice
that
once
it
goes
through
the
install
and
hopefully
it'll
go
fairly.
Quick
should
be
a
small
install.
What's
gonna
happen.
Is
it's
going
to
actually
eliminate
my
assembling?
A
It's
gonna
remove
it
and
we
should
see
some
red
squigglies
occur
here
when
it
completes,
and
that
means
that
it
is
essentially
removed.
My
sim
link
and
now,
if
I,
were
to
try
to
do
a
gold
or
bundle
or
ship
or
serve,
then
it
would
fail
essentially
telling
us
that
my
library
component
cannot
be
found,
etc,
etc,
and
so,
as
soon
as
this
finishes
we'll
see
this
get
updated
and
I've
got
it
sorted
by
date
modified.
So
we
can
see
the
most
recent
change
and
we're
gonna
see
PN
pjs
added
in
there
on
done.
A
There
we
go,
we
can
see
the
staging
and
there
we
go.
Pnp
is
now
there,
which
is
great,
but
we
notice
over
here
we've
got
some
red
squigglies
and
some
errors,
so
no
problem,
real
quick
fix,
simply
is
just
that.
You
need
to
reinstate
the
sim
link.
So
you
just
do
an
NPM
link,
the
name
of
our
library
component.
It
will
very
rapidly
reinstate.
We
see
it's
added
back
in
and
now
everything
is
fine.
A
Now,
just
one
quick
note,
if
you
have
already
added
it,
which
I
have
not
done
yet
to
your
package
JSON,
it
may
throw
an
error.
When
you
try
to
install
things
saying
I
can't
find
your
sim
link,
you
could
just
simply
go
in
and
temporarily
remove
that.
All
of
this
is
documented
on
the
documentation
for
library
components,
but
you
just
wanted
I
wanted
to
show
you
guys.
Just
in
case
you
were
working
with
it.
If
you're
not
already
paying
attention
to
your
node
modules,
then
it
could
definitely
trip
you
up
and
you.